Log in

View Full Version : ffmpeg -bsf:v hevc_metadata... Any way to change Mastering Display Luminance?


bokeron2020
16th August 2023, 23:18
Hi!!

I made an ugly and stupid mistake while encoding that ended up with 20 files which Mastering Display Luminance values are reversed. I mean, instead of Mediainfo showing:

Mastering display luminance : min: 0.0000 cd/m2, max: 1000 cd/m2

it shows instead:

Mastering display luminance : min: 1000.0000 cd/m2, max: 0 cd/m2



Apparentlyt there's no way to change that using ffmeg bitstream filter... but maybe there is? Or... is there any other way that can repair this without reencoding?

Thanks for any help you can provide.

quietvoid
17th August 2023, 00:44
There are ffmpeg patches that add the capability to edit HDR metadata AFAIK..
I don't have them on hand.

bokeron2020
17th August 2023, 01:09
There are ffmpeg patches that add the capability to edit HDR metadata AFAIK..
I don't have them on hand.

Oh, thank you. Didn't know about that. I've done a quick search right now and I've found something apparently compiled for Nvida encoder... I downloaded and tried it but no luck.

I wonder why isn't this a capability already incorporated to the "mainstream" builds. Maybe some drawback doing this even if it was finally possible?

I better start re-encoding... just in case... :rolleyes: