]> rtime.felk.cvut.cz Git - frescor/ffmpeg.git/blobdiff - libavcodec/h263dec.c
Add a chroma_sample_location field to define positioning of chroma samples
[frescor/ffmpeg.git] / libavcodec / h263dec.c
index fa8fd1f9ab1b7bde22ee65f84a0d3d0f9b8f4f0e..b087933f665a46e042818cb6aaf99e3255c2c52a 100644 (file)
@@ -59,12 +59,14 @@ av_cold int ff_h263_decode_init(AVCodecContext *avctx)
     switch(avctx->codec->id) {
     case CODEC_ID_H263:
         s->unrestricted_mv= 0;
+        avctx->chroma_sample_location = AVCHROMA_LOC_CENTER;
         break;
     case CODEC_ID_MPEG4:
         s->decode_mb= ff_mpeg4_decode_mb;
         s->time_increment_bits = 4; /* default value for broken headers */
         s->h263_pred = 1;
         s->low_delay = 0; //default, might be overriden in the vol header during header parsing
+        avctx->chroma_sample_location = AVCHROMA_LOC_LEFT;
         break;
     case CODEC_ID_MSMPEG4V1:
         s->h263_msmpeg4 = 1;
@@ -96,6 +98,7 @@ av_cold int ff_h263_decode_init(AVCodecContext *avctx)
         s->h263_msmpeg4 = 1;
         s->h263_pred = 1;
         s->msmpeg4_version=6;
+        avctx->chroma_sample_location = AVCHROMA_LOC_LEFT;
         break;
     case CODEC_ID_H263I:
         break;