
- Posts: 60
- Joined: Wed Apr 12, 2017 4:40 am
Hi,
Short: Is there any SDK available for input format on resolve 17.1?
Long:
Few weeks ago I got a Gopro Max. I did not have any idea what can I do with this tool.
But I found http://reframe360.com , no luck Stefan Sietzen stop the development and only a beta for Windows exists. But the work he made is fantastic.
So I decided to port it to MacOS with Metal hardware acceleration. I succeed. It works very well well with realtime 5.6k processing (on Macbook pro 15 i9 with Radeon).
After that another developer contact me because it adds some (very) nice features and he wants to merge my work…
So now we have (I make MacOS/Metal/OpenCL, Sylvain Windows/Linux Cuda/openCL) a working OpenFX plugin for reframing equirectangular videos.
My repository https://github.com/eltorio/reframe360XL
Sylvain's one https://github.com/LRP-sgravel/reframe360XL
Good there is something to do with the Gopro Max
But it is not enough for me. In fact Gopro Max generates .360 video files. These are standard multistream MP4 files, streams 0 and 4 are front and rear (almost) EAC projection https://en.wikipedia.org/wiki/360_video_projection not standard equirectangular.
For getting equirectangular video, you need to use the ugly GoPro player and the only option you have is to export to Apple ProRes and lose the advantage of EAC projected files, with x10 size increase.
So I want to find a solution for using directly the .360 in DaVinci Resolve.
I know that there is a sample h264 encoder based on libx264 in the DaVinci Resolve IO Encode Plugin SDK, but I do not see any decoder Plugin sample.
As a proof of concept I started to make a libavfilter FFmpeg opencl filter for producing an equirectangular or a equiangular-cubempap projected file.
This is the code on my Github repository https://github.com/eltorio/FFmpeg
This is the current patch against FFmpeg head.
Work in progress patch to FFmpeg
Code is far from being perfect. For example Gopro player automatically apply a rotation matrix for virtually keeping the horizon. Also they apply something like interpolation on the two lenses overlapping area…
It needs a lot of work for having the same quality.
On a MacBook Pro 15 with Radeon Pro Vega 16 I test with:
For having the ouptut in standard equirectangular with embedded OpenCL equiangular-cubemap to equirectangular reprojection:
For having the ouptut in standard equiangular-cubemap projection:
For having the ouptut in standard equirectangular with v360 filter:
On a iMac Pro device is opencl:0.1
The performance of the libavfiler is near realtime with native GoPro Max 5376x2688 resolution.
I'd like to write something for DaVinci Resolve
Short: Is there any SDK available for input format on resolve 17.1?
Long:
Few weeks ago I got a Gopro Max. I did not have any idea what can I do with this tool.
But I found http://reframe360.com , no luck Stefan Sietzen stop the development and only a beta for Windows exists. But the work he made is fantastic.
So I decided to port it to MacOS with Metal hardware acceleration. I succeed. It works very well well with realtime 5.6k processing (on Macbook pro 15 i9 with Radeon).
After that another developer contact me because it adds some (very) nice features and he wants to merge my work…
So now we have (I make MacOS/Metal/OpenCL, Sylvain Windows/Linux Cuda/openCL) a working OpenFX plugin for reframing equirectangular videos.
My repository https://github.com/eltorio/reframe360XL
Sylvain's one https://github.com/LRP-sgravel/reframe360XL
Good there is something to do with the Gopro Max
But it is not enough for me. In fact Gopro Max generates .360 video files. These are standard multistream MP4 files, streams 0 and 4 are front and rear (almost) EAC projection https://en.wikipedia.org/wiki/360_video_projection not standard equirectangular.
For getting equirectangular video, you need to use the ugly GoPro player and the only option you have is to export to Apple ProRes and lose the advantage of EAC projected files, with x10 size increase.
So I want to find a solution for using directly the .360 in DaVinci Resolve.
I know that there is a sample h264 encoder based on libx264 in the DaVinci Resolve IO Encode Plugin SDK, but I do not see any decoder Plugin sample.
As a proof of concept I started to make a libavfilter FFmpeg opencl filter for producing an equirectangular or a equiangular-cubempap projected file.
This is the code on my Github repository https://github.com/eltorio/FFmpeg
This is the current patch against FFmpeg head.
Work in progress patch to FFmpeg
Code is far from being perfect. For example Gopro player automatically apply a rotation matrix for virtually keeping the horizon. Also they apply something like interpolation on the two lenses overlapping area…
It needs a lot of work for having the same quality.
- Code: Select all
Build with
./configure --enable-opencl --enable-videotoolbox --disable-x86asm --enable-libx264 --enable-libx265 --enable-gpl
make
On a MacBook Pro 15 with Radeon Pro Vega 16 I test with:
For having the ouptut in standard equirectangular with embedded OpenCL equiangular-cubemap to equirectangular reprojection:
- Code: Select all
./ffmpeg -hwaccel auto -hwaccel auto -init_hw_device opencl:0.2 -filter_hw_device opencl0 -v verbose -filter_complex '[0:0]format=yuv420p,hwupload[a] , [0:4]format=yuv420p,hwupload[b], [a][b]gopromax_opencl, hwdownload,format=yuv420p' -i GS010035.360 -f sdl2 -
For having the ouptut in standard equiangular-cubemap projection:
- Code: Select all
./ffmpeg -hwaccel auto -hwaccel auto -init_hw_device opencl:0.2 -filter_hw_device opencl0 -v verbose -filter_complex '[0:0]format=yuv420p,hwupload[a] , [0:4]format=yuv420p,hwupload[b], [a][b]gopromax_opencl=eac=1, hwdownload,format=yuv420p' -i GS010035.360 -f sdl2 -
For having the ouptut in standard equirectangular with v360 filter:
- Code: Select all
./ffmpeg -hwaccel auto -hwaccel auto -init_hw_device opencl:0.2 -filter_hw_device opencl0 -v verbose -filter_complex '[0:0]format=yuv420p,hwupload[a] , [0:4]format=yuv420p,hwupload[b], [a][b]gopromax_opencl=eac=1, hwdownload,format=yuv420p, v360=input=eac:output=e' -i GS010035.360 -f sdl2 -
On a iMac Pro device is opencl:0.1
The performance of the libavfiler is near realtime with native GoPro Max 5376x2688 resolution.
I'd like to write something for DaVinci Resolve