History

avutil/hwcontext_videotoolbox: Correctly set trc

The color trc key was assigned a color primaries value which causes the resulting colorspace is always SDR. Fixes #10884.

Gnattu OC committed 2 years ago

Commit d50f9701 parent 1b2a9251 file · +1 −1Browse files

Unified · Split

libavutil/hwcontext_videotoolbox.c+1−1
@@ -597,7 +597,7 @@ static int vt_pixbuf_set_colorspace(void *log_ctx, · 596 unmodified lines
597 colortrc = av_map_videotoolbox_color_trc_from_av(src->color_trc);597 colortrc = av_map_videotoolbox_color_trc_from_av(src->color_trc);
598 if (colortrc)598 if (colortrc)
599 CVBufferSetAttachment(pixbuf, kCVImageBufferTransferFunctionKey,599 CVBufferSetAttachment(pixbuf, kCVImageBufferTransferFunctionKey,
600 colorpri, kCVAttachmentMode_ShouldPropagate);600 colortrc, kCVAttachmentMode_ShouldPropagate);
601 else {601 else {
602 CVBufferRemoveAttachment(pixbuf, kCVImageBufferTransferFunctionKey);602 CVBufferRemoveAttachment(pixbuf, kCVImageBufferTransferFunctionKey);
603 if (src->color_trc != AVCOL_TRC_UNSPECIFIED)603 if (src->color_trc != AVCOL_TRC_UNSPECIFIED)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t