diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-06-28 12:13:05 +0200 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-06-30 15:34:38 +0200 |
commit | 271ce76d317c5432e151216cf23f12b77ed6cb7e (patch) | |
tree | 6ab18a33d1ac6d090aa187c942e26834491aff95 /libavcodec/h264.c | |
parent | 0bfab80a0d9fce0180e8aa2a947267f89b725091 (diff) | |
download | ffmpeg-271ce76d317c5432e151216cf23f12b77ed6cb7e.tar.gz |
h264: Parse registered data SEI message and AFD value
Partially based on code by Marton Balint and Kieran Kunhya.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 6fd238d444..6925a8ac31 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -822,6 +822,16 @@ static void decode_postinit(H264Context *h, int setup_finished) h->sei_hflip, h->sei_vflip); } + if (h->sei_reguserdata_afd_present) { + AVFrameSideData *sd = av_frame_new_side_data(cur->f, AV_FRAME_DATA_AFD, + sizeof(uint8_t)); + if (!sd) + return; + + *sd->data = h->active_format_description; + h->sei_reguserdata_afd_present = 0; + } + // FIXME do something with unavailable reference frames /* Sort B-frames into display order */ |