Browse Source

libavcodec: set AVFrame colorspace fields on decoding

Signed-off-by: Anton Khirnov <anton@khirnov.net>
tags/n2.3
wm4 Anton Khirnov 11 years ago
parent
commit
eb800f120d
1 changed files with 7 additions and 0 deletions
  1. +7
    -0
      libavcodec/utils.c

+ 7
- 0
libavcodec/utils.c View File

@@ -580,6 +580,13 @@ int ff_decode_frame_props(AVCodecContext *avctx, AVFrame *frame)
int size;
AVFrameSideData *frame_sd;

#if FF_API_AVFRAME_COLORSPACE
frame->color_primaries = avctx->color_primaries;
frame->color_trc = avctx->color_trc;
frame->colorspace = avctx->colorspace;
frame->color_range = avctx->color_range;
frame->chroma_location = avctx->chroma_sample_location;
#endif

frame->reordered_opaque = avctx->reordered_opaque;
if (!pkt) {


Loading…
Cancel
Save