summaryrefslogtreecommitdiff
path: root/libavcodec/av1_parser.c
Commit message (Collapse)AuthorAge
* avcodec: remove FF_API_AVCTX_TIMEBASEJames Almer2023-02-09
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: export timing information when presentJames Almer2023-01-10
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* all: Remove unnecessary libavcodec/internal.h inclusionsAndreas Rheinhardt2022-02-08
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/av1_parser: constify some variablesJames Almer2021-09-24
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec: Move all AVCodecParser.split functions to remove_extradata_bsfAndreas Rheinhardt2021-04-27
| | | | | | | The remove_extradata bsf is the only user of these functions. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec: Constify all the AVCodecParsersAndreas Rheinhardt2021-04-27
| | | | | | | Possible now that the next pointer no longer exists. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/cbs: constify decompose_unit_typesJames Almer2021-01-10
| | | | | | | CBS doesn't change its contents in any way whatsoever internally, and most users already set it to a const array. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1{dec,parser}: move to ff_cbs_read_extradata_from_codecJan Ekström2020-11-24
| | | | | | This lets us re-utilize the extradata-related checks in the CBS to add support for passing the AV1CodecConfigurationRecord as extradata as-is without further filtering.
* avcodec/av1_parser: don't set AVCodecContext frame dimensionsJames Almer2020-09-12
| | | | | | | Let the internal decoder take care of it, as frame reordering may result in different values exported by either module. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: don't set AVCodecContext pixel formatJames Almer2020-09-12
| | | | | | This is a property a decoder must set, not a parser. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: fix parsing show_existing_frame headersJames Almer2020-08-25
| | | | | | Regression since c8716b5029 Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: read frame properties directly from AV1RawFrameHeaderJames Almer2020-08-23
| | | | | | | Simplifies code Reviewed-by: Mark Thompson <sw@jkqxz.net> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/cbs: Remove unused function parametersAndreas Rheinhardt2020-07-07
| | | | | | | | Several cbs-functions had an unused CodedBitstreamContext parameter. This commit removes these. Reviewed-by: Mark Thompson <sw@jkqxz.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/av1_parser: initialize avctx->pix_fmtManoj Bonda2020-06-19
| | | | | | | | | | | Initialize avctx->pix_fmt in av1_parser.c AV1 Chroma format is invalid when quering using below code if no AV1 decoder is available: iVideoStream = av_find_best_stream(fmtc, AVMEDIA_TYPE_VIDEO, -1, -1, NULL, 0); eChromaFormat = (AVPixelFormat)fmtc->streams[iVideoStream]->codecpar->format; Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: add missing parsing for RGB pixel format signalingJames Almer2020-06-19
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: set context values outside the OBU parsing loopJames Almer2020-06-19
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: export color informationJames Almer2020-01-26
| | | | | | | Should fix fate-lavf-fate-av1.mkv failures on builds without an AV1 decoder. Tested-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: skip frames with spatial_id > 0James Almer2019-12-02
| | | | | | This fixes marking keyframes in svc samples. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: export stream dimensions in avctxJames Almer2019-11-29
| | | | | | This is required to demux annexb samples when a decoder isn't available. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: export bitstream timing info when availableJames Almer2019-11-12
| | | | | | Based on h264_parser code. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/av1_parser: don't abort parsing the first frame if extradata parsing ↵James Almer2019-03-24
| | | | | | | | | | | fails The first frame contains the sequence header, which is needed to parse every following frame. This fixes parsing streams with broken extradata but correct packet data. Signed-off-by: James Almer <jamrial@gmail.com>
* libavcodec/cbs: Stop needlessly reallocating the units arrayAndreas Rheinhardt2019-02-25
| | | | | | | | | | | | | | | | | Currently, a fragment's unit array is constantly reallocated during splitting of a packet. This commit changes this: One can keep the units array by distinguishing between the number of allocated and the number of valid units in the units array. The more units a packet is split into, the bigger the benefit. So MPEG-2 benefits the most; for a video coming from an NTSC-DVD (usually 32 units per frame) the average cost of cbs_insert_unit (for a single unit) went down from 6717 decicycles to 450 decicycles (based upon 10 runs with 4194304 runs each); if each packet consists of only one unit, it went down from 2425 to 448; for a H.264 video where most packets contain nine units, it went from 4431 to 450. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@googlemail.com>
* avcodec: add an AV1 parserJames Almer2018-10-03
Simple parser to set keyframes, frame type, structure, width, height, and pixel format, plus stream profile and level. Reviewed-by: Mark Thompson <sw@jkqxz.net> Signed-off-by: James Almer <jamrial@gmail.com>