[vlc-devel] [PATCH] [WIP] RFC: add HDR/BT.2020 support (using libplacebo)
remi at remlab.net
Thu Oct 26 19:01:07 CEST 2017
Le torstaina 26. lokakuuta 2017, 0.59.56 EEST Niklas Haas a écrit :
> Attached is my preliminary patch for how to use libplacebo
> (https://github.com/haasn/libplacebo) to convert between color spaces in
> VLC, including HDR->SDR tone mapping. libplacebo is an ongoing project
> to develop the GLSL rendering system from the mpv project into an
> independent, reusable library.
> Remaining issues that need to be resolved:
> - It needs to be added to the build system. Due to the early nature of
> libplacebo and the unstable API that results from it, it should be
> configured to use a pinned commit and build the library statically.
> - libplacebo requires LC_NUMERIC="C" (so `snprintf` works). I'm not sure
> what the best way to accomplish this in VLC is; but one way is to use
> `uselocale` from opengl/vout_helper.c to explicitly set the locale for
> that thread.
You can´t be serious?! Such a horrible abstraction leakage.
> Alternatively, I could try making libplacebo set the
> locale back and forth in every function so as to not depend on it, but
> I'd rather not if I can avoid it.
VLC has its own convenience wrapper for that. Obviously, that can´t be used
for by an external library. But you can use a similar solution.
> - We should use libplacebo in more ways, for example to replace the
> YUV->RGB conversion code (which would also allow VLC to support the
> proper BT.2020 transformation including BT.2020-CL; and also allow VLC
> to get rid of the special cased code for XYZ12). But I think this
> would probably be better off as a second/separate commit.
> Thoughts? Milestone?
More information about the vlc-devel