diff options
author | Will Kelleher <wkelleher@gogoair.com> | 2015-11-06 14:48:46 -0600 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2015-11-07 12:10:55 +0100 |
commit | 7f7fa90f7b7fccecff98bb1cef307e093dac1d29 (patch) | |
tree | 2068ed037238083f1cfc465b3672836fd52885b7 /libavcodec/hevc.c | |
parent | 43492ff3ab68a343c1264801baa1d5a02de10167 (diff) | |
download | ffmpeg-7f7fa90f7b7fccecff98bb1cef307e093dac1d29.tar.gz |
hevc: extract SEI caption data
Signed-off-by: Will Kelleher <wkelleher@gogoair.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/hevc.c')
-rw-r--r-- | libavcodec/hevc.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/hevc.c b/libavcodec/hevc.c index 4b3f19998c..1fa5283da3 100644 --- a/libavcodec/hevc.c +++ b/libavcodec/hevc.c @@ -2566,6 +2566,16 @@ static int set_side_data(HEVCContext *s) s->sei_hflip, s->sei_vflip); } + if (s->a53_caption) { + AVFrameSideData* sd = av_frame_new_side_data(out, + AV_FRAME_DATA_A53_CC, + s->a53_caption_size); + if (sd) + memcpy(sd->data, s->a53_caption, s->a53_caption_size); + av_freep(&s->a53_caption); + s->avctx->properties |= FF_CODEC_PROPERTY_CLOSED_CAPTIONS; + } + return 0; } |