0
$\begingroup$

In this video :

Blender VSE: Guide III (3d-viewport, hotkeys, 10 bit h.264, + more!) - YouTube

I finally found a way to convert my EXR files to 10bit H264 Video. The command I use is as follows:

ffmpeg -framerate 30 -i %04d.exr -c:v libx264 -crf 17 -pix_fmt yuv422p10le -vf "eq=exposure=1.0" output_17.mkv

Unfortunately, the video is much too dark and doesn't have the correct exposure as well as the other color management settings done in Blender.

color management settings in Blender

Is there any way to get the exact ffmpeg parameters Blender is using when exporting a video, so I can adjust them to yuv422?
Or maybe there is a better workflow for getting a 10bit video without banding? I tried working with the EXR files and Davinci Resolve, unfortunately 10bit H264 / H265 export isn't possible in the free version. So the easiest way might be FFMPEG with the right parameters.


Thanks for your answer.

Seems I posted the wrong command that I was able to run. Instead of:

ffmpeg -framerate 30 -i %04d.exr -c:v libx264 -crf 17 -pix_fmt yuv422p10le -vf "eq=exposure=1.0" output_17.mkv

only the following was working for me:

ffmpeg -framerate 30 -i %04d.exr -c:v libx264 -crf 17 -pix_fmt yuv422p10le  output_17.mkv

When using the -vf part, I get the following error:

enter image description here

When using your -vf parameter, the error is the same:

enter image description here

So I think there must be different parameter instead of the two I used.

But I think the LUTs will be the right way to get it working, if we can figure out the right command :) I used these LUTs in Resolve before, and they worked great. Unfortunately I wasn't able to export 10 bit afterwards (with the free version).

$\endgroup$
2
  • 1
    $\begingroup$ I would try some other format than EXR because EXR stores linear color without any color management. 16 bit TIFF might work the way you want. $\endgroup$ Oct 23, 2022 at 18:51
  • $\begingroup$ Nobody is warned when you edit your original post. When you want to react on someone's answer, post a comment just beneath it. I updated my answer, please see below and let me know the result. $\endgroup$
    – L0Lock
    Oct 24, 2022 at 2:24

1 Answer 1

0
$\begingroup$

Not an expert, but Blender EXRs don't store any of the color management settings besides the space if I'm right. So the "Look", "Exposure" and "Gamma" are not written in your files.

As explained in FFmpeg Filters Documentation - Filtering Introduction:

Filters in the same linear chain are separated by commas, and distinct linear chains of filters are separated by semicolons.

As for the eq filter, again according to FFmpeg Filters Documentation - eq:

Set brightness, contrast, saturation and approximate gamma adjustment.

So no exposure option in the eq filter, hence the error. But exposure is a filter itself, so you can use it as is without eq.

Changing the gamma and exposure should be as simple as -vf "exposure=1.0,eq=gamma=1.0". But for the "Look" setting, I'm unsure of what to do without using LUT files.

From the Filmic-Blender documentation:

Look Transforms

A set of Look transforms that include:

  1. Greyscale. This Look is based off of the Filmic Log Encoding Base and will deliver a weighted greyscale version of the image. The weights used are for REC.709 RGB lights, which are the same lights specified in sRGB.

  2. Five contrast base looks for use with the Filmic Log Encoding Base. All map middle grey 0.18 to 0.5 display referred. Each has a smooth roll off on the shoulder and toe. They include:


Source: sobotka/filmic-blender: Film Emulsion-Like Camera Rendering Transforms for Blender

Maybe you can try to use the developer's Filmic LUT files for Davinci Resolve:

sobotka/filmic-resolve: Filmic Resolve Cube LUTs

These are 1D LUT files, so use the lut1d filter. Though in other cases, you will more often have to deal with 3D LUT files with the lut3d filter. Using the wrong command will result in an "empty LUT" error.

There is one .cube file per Filmic look. In FFMPEG, you would just need to add this to change your video filter tag:

-vf "exposure=1.0,eq=gamma=1.0,lut1d=lut_file.cube"

If it gives error like "exposure/lut1d not found", try replacing the -vf argument and options by this:

-filter_complex "[0:v]exposure=1.0,eq=gamma=1.0,lut3d=lut_file.cube"

For simplicity's sake, make sure the LUT file is in the same folder as the EXRs and that you are running your command from that folder.

$\endgroup$
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .