[FFmpeg-devel] SDR->HDR tone mapping algorithm?
Vittorio Giovara
vittorio.giovara at gmail.com
Fri Feb 8 13:20:23 EET 2019
On Fri, Feb 8, 2019 at 3:22 AM Harish Krupo <harish.krupo.kps at intel.com>
wrote:
> Hello,
>
> We are in the process of implementing HDR rendering support in the
> Weston display compositor [1] (HDR discussion here [2]). When HDR
> and SDR surfaces like a video buffer and a subtitle buffer are presented
> together, the composition would take place as follows:
> - If the display does not support HDR metadata:
> in-coming HDR surfaces would be tone mapped using opengl to SDR and
> blended with the other SDR surfaces. We are currently using the Hable
> operator for tone mapping.
> - If the display supports setting HDR metadata:
> SDR surfaces would be tone mapped to HDR and blended with HDR surfaces.
>
> The literature available for SDR->HDR tone mapping varies from simple
> linear expansion of luminance to CNN based approaches. We wanted to know
> your recommendations for an acceptable algorithm for SDR->HDR tone mapping.
>
> Any help is greatly appreciated!
>
> [1] https://gitlab.freedesktop.org/wayland/weston
> [2]
> https://lists.freedesktop.org/archives/wayland-devel/2019-January/039809.html
>
> Thank you
> Regards
> Harish Krupo
>
In *theory* the tonemapping functions should be reversible, so if you use
vf_tonemap or vf_tonemap_opencl and properly expand the range via zimg
(vf_zscale) before compression it should work fine. However I have never
tried it myself, so I cannot guarantee that those filters will work as is.
Of course haasn from the libplacebo project might have better suggestions,
so you should really reach out to him.
--
Vittorio
More information about the ffmpeg-devel
mailing list