The color trc key was assigned a color primaries value which causes the resulting colorspace is always SDR. Fixes #10884.
Unified · Split
| @@ -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) |