[vlc-devel] [PATCH] video_out/mac: Enable bt2020 color space
vittorio.giovara at gmail.com
Sun Oct 2 22:51:03 CEST 2016
On Sun, Oct 2, 2016 at 2:53 PM, Jean-Baptiste Kempf <jb at videolan.org> wrote:
> On 02 Oct, Vittorio Giovara wrote :
>> On Sun, Oct 2, 2016 at 11:38 AM, Felix Paul Kühne <fkuehne at videolan.org> wrote:
>> > Hey Vittorio,
>> > This patch needs a ifdef in case kCGColorSpaceITUR_2020 is not defined (as it was introduced in macOS 10.11 and we still want to support the 10.10 SDK) similar to what we do for other constants like in the VideoToolbox decoder.
>> Hi Felix,
>> would something like
>> #if MAC_OS_X_VERSION_MAX_ALLOWED < 1011
>> const CFStringRef kCGColorSpaceITUR_2020 = CFSTR("kCGColorSpaceITUR_2020");
>> in both files be enough?
> I think so.
> But what happens at runtime, if you don't have this supported?
"A new generic color space. You are responsible for releasing this
object by calling CGColorSpaceRelease. If unsuccessful, returns NULL."
So the two uses
[sys->cgLayer setColorspace: sys->cgColorSpace];
sys->nsColorSpace = [[NSColorSpace alloc]
will just basically be noops.
Not sure if there is any extra implications.
More information about the vlc-devel