diff options
author | Derek Buitenhuis <derek.buitenhuis@gmail.com> | 2016-04-26 13:38:45 +0100 |
---|---|---|
committer | Derek Buitenhuis <derek.buitenhuis@gmail.com> | 2016-04-26 13:56:47 +0100 |
commit | 3c4ca4c5d7992e545a6cbad440287f9e27f1a696 (patch) | |
tree | 110fffd8d88093550fa8a023e513542ac4742fda /libavcodec/hevc_parser.c | |
parent | 492d229303a8d4270eda4d3be0e45d9e0caad0a8 (diff) | |
parent | fa936a307f5cddfc2664600157a8207ca8080af6 (diff) | |
download | ffmpeg-3c4ca4c5d7992e545a6cbad440287f9e27f1a696.tar.gz |
Merge commit 'fa936a307f5cddfc2664600157a8207ca8080af6'
* commit 'fa936a307f5cddfc2664600157a8207ca8080af6':
hevc_parse: rename into h2645_parse
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Diffstat (limited to 'libavcodec/hevc_parser.c')
-rw-r--r-- | libavcodec/hevc_parser.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/libavcodec/hevc_parser.c b/libavcodec/hevc_parser.c index 59893bb3e1..71887a8e91 100644 --- a/libavcodec/hevc_parser.c +++ b/libavcodec/hevc_parser.c @@ -24,6 +24,7 @@ #include "golomb.h" #include "hevc.h" +#include "h2645_parse.h" #include "parser.h" #define START_CODE 0x000001 ///< start_code_prefix_one_3bytes @@ -35,7 +36,7 @@ typedef struct HEVCParserContext { ParseContext pc; - HEVCPacket pkt; + H2645Packet pkt; HEVCParamSets ps; int parsed_extradata; @@ -46,7 +47,7 @@ typedef struct HEVCParserContext { } HEVCParserContext; #if !ADVANCED_PARSER -static int hevc_parse_slice_header(AVCodecParserContext *s, HEVCNAL *nal, +static int hevc_parse_slice_header(AVCodecParserContext *s, H2645NAL *nal, AVCodecContext *avctx) { HEVCParserContext *ctx = s->priv_data; @@ -88,12 +89,12 @@ static int parse_nal_units(AVCodecParserContext *s, const uint8_t *buf, HEVCParserContext *ctx = s->priv_data; int ret, i; - ret = ff_hevc_split_packet(NULL, &ctx->pkt, buf, buf_size, avctx, 0, 0); + ret = ff_h2645_split_packet(&ctx->pkt, buf, buf_size, avctx, 0, 0); if (ret < 0) return ret; for (i = 0; i < ctx->pkt.nb_nals; i++) { - HEVCNAL *nal = &ctx->pkt.nals[i]; + H2645NAL *nal = &ctx->pkt.nals[i]; /* ignore everything except parameter sets and VCL NALUs */ switch (nal->type) { @@ -189,10 +190,10 @@ static inline int parse_nal_units(AVCodecParserContext *s, const uint8_t *buf, GetBitContext *gb; SliceHeader *sh = &h->sh; HEVCParamSets *ps = &h->ps; - HEVCPacket *pkt = &ctx->pkt; + H2645Packet *pkt = &ctx->pkt; const uint8_t *buf_end = buf + buf_size; int state = -1, i; - HEVCNAL *nal; + H2645NAL *nal; int is_global = buf == avctx->extradata; if (!h->HEVClc) @@ -213,7 +214,7 @@ static inline int parse_nal_units(AVCodecParserContext *s, const uint8_t *buf, return 0; if (pkt->nals_allocated < 1) { - HEVCNAL *tmp = av_realloc_array(pkt->nals, 1, sizeof(*tmp)); + H2645NAL *tmp = av_realloc_array(pkt->nals, 1, sizeof(*tmp)); if (!tmp) return AVERROR(ENOMEM); pkt->nals = tmp; @@ -239,7 +240,7 @@ static inline int parse_nal_units(AVCodecParserContext *s, const uint8_t *buf, src_length = 20; } - consumed = ff_hevc_extract_rbsp(buf, src_length, nal); + consumed = ff_h2645_extract_rbsp(buf, src_length, nal); if (consumed < 0) return consumed; |