diff options
author | Mark Thompson <sw@jkqxz.net> | 2016-10-26 20:27:57 +0100 |
---|---|---|
committer | Mark Thompson <sw@jkqxz.net> | 2016-10-31 19:23:40 +0000 |
commit | 0c559f7893e6f47aad1b0c1429287eaa218ec87c (patch) | |
tree | 0ef8cb26199d00a5de202c55df46a800acd0002d /libavcodec/hevc_parser.c | |
parent | 4df6605da7e351116c99f19b8a98e1f236932600 (diff) | |
download | ffmpeg-0c559f7893e6f47aad1b0c1429287eaa218ec87c.tar.gz |
hevc: Return stream format information from parser
Diffstat (limited to 'libavcodec/hevc_parser.c')
-rw-r--r-- | libavcodec/hevc_parser.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/hevc_parser.c b/libavcodec/hevc_parser.c index d93586ba7d..508f22f46d 100644 --- a/libavcodec/hevc_parser.c +++ b/libavcodec/hevc_parser.c @@ -312,6 +312,14 @@ static inline int parse_nal_units(AVCodecParserContext *s, const uint8_t *buf, ps->vps = (HEVCVPS*)ps->vps_list[ps->sps->vps_id]->data; } + s->coded_width = ps->sps->width; + s->coded_height = ps->sps->height; + s->width = ps->sps->output_width; + s->height = ps->sps->output_height; + s->format = ps->sps->pix_fmt; + avctx->profile = ps->sps->ptl.general_ptl.profile_idc; + avctx->level = ps->sps->ptl.general_ptl.level_idc; + if (!sh->first_slice_in_pic_flag) { int slice_address_length; |