7

I want to convert 360 videos from equirectangular to cubic projection. How can I do this with ffmpeg? What are other efficient open source approaches?

Guig
  • 9,891
  • 7
  • 64
  • 126

3 Answers3

5

Use native FFmpeg v360 filter, it supports more features that any other solution.

5

You need the v360 filter (make sure you use the latest ffmpeg build as older versions don't include it).

For instance:

-vf v360=equirect:c3x2

3x2/6x1/1x6 cubemap layouts are available.

Pamphile
  • 1,566
  • 12
  • 15
4

You can try out by compiling with the transform filter, developed by Facebook

Transform

Transform is a video filter that transforms 360 video in equirectangular projection into a cubemap projection

Build Instructions:

Transform is implemented as an ffmpeg video filter. To build Transform, follow these steps:

Checkout the source for ffmpeg

Copy vf_transform.c to the libavfilter subdirectory in ffmpeg source

Edit libavfilter/allfilters.c and register the filter by adding the line: REGISTER_FILTER(TRANSFORM, transform, vf); in the video filter registration section

Edit libavfilter/Makefile and add the filter to adding the line: OBJS-$(CONFIG_TRANSFORM_FILTER) += vf_transform.o in the filter section

Configure and build ffmpeg as usual

Community
  • 1
  • 1
Gyan
  • 85,394
  • 9
  • 169
  • 201
  • Works very well, thanks for pointing out this recent ressource. I haven't found yet how to make it work with OSX brew workflow but it's super easy to get running on Linux – Guig Feb 03 '16 at 19:46