summaryrefslogtreecommitdiff
path: root/libavformat/argo_brp.c
Commit message (Collapse)AuthorAge
* avformat/argo_brp: use bits_per_coded_sample instead of bits_per_raw_sampleZane van Iperen2021-07-19
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat: Constify all muxer/demuxersAndreas Rheinhardt2021-04-27
| | | | | | | This is possible now that the next-API is gone. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/argo_brp: remove block_align check for audioZane van Iperen2020-11-05
| | | | | | | | | | | | | | | | | Causes a divide-by-zero in the rare case where: - the file has an audio stream, - the first audio frame isn't within the first BRP_BASF_LOOKAHEAD frames, - an audio frame is encountered later, and - its chunk header (except num_blocks) contains all zeros (matching the uninitialised structure in the context) The decoder will discard any garbage data, so the check isn't really needed. Fixes: division by 0 Fixes: 26667/clusterfuzz-testcase-minimized-ffmpeg_dem_ARGO_BRP_fuzzer-5645146928185344.fuzz Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: bail if no video framesZane van Iperen2020-11-03
| | | | | | | | | Fixes: Assertion failure Fixes: 26572/clusterfuzz-testcase-minimized-ffmpeg_dem_ARGO_BRP_fuzzer-5166735591997440 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avcodec: add Argonaut Games Video decoderPaul B Mahol2020-09-27
|
* avformat/argo_brp: use header frame countsZane van Iperen2020-09-27
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: allow v1.1 ASF streams to have a non-22050 sample rate in ↵Zane van Iperen2020-09-27
| | | | | | | | | | | | | | | | certain circumstances It seems that in files where the BASF block isn't first, v1.1 ASF streams are allowed to be non-22050. Either this format is really inconsistent, or FX Fighter and Croc just ignored the sample rate field, requiring the v1.1 restriction in the first place. This bumps the version to 1.2 in these streams so they're not "corrected". Found in Alien Odyssey games files in: ./GRAPHICS/COMMBUNK/{{COMADD1,COMM2_{1,2,3E},COMM3_{2,3,4,5,6}},FADE{1,2}}.BRP Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: cosmeticsZane van Iperen2020-09-27
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: handle the case where the BASF block isn't the firstZane van Iperen2020-09-27
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: support MASK streamsZane van Iperen2020-09-27
| | | | | | We can't actually use them though. Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_{asf,brp}: fix potential segfault in ff_argo_asf_fill_stream()Zane van Iperen2020-09-27
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: don't pass AVStream into avpriv_request_sample()Zane van Iperen2020-09-20
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: set BVID packet durationZane van Iperen2020-09-20
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: handle multiple BASF blocksZane van Iperen2020-09-20
| | | | | | | Turns out that there are files with multiple (reasonably-sized) BASF blocks. Some of the files just have particularly large frames (~10s). Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: make sure stream ids matchZane van Iperen2020-09-20
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: cleanup 'goto fail'sZane van Iperen2020-09-20
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_brp: remove an allocationZane van Iperen2020-09-20
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat/argo_{asf,brp}: use variable frame sizes when (de)muxing adpcm_argoZane van Iperen2020-09-19
| | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* avformat: add Argonaut Games BRP demuxerZane van Iperen2020-09-14
Used in FMVs for FX Fighter and Croc. Supports BVID and BASF streams, requests samples for anything else. Due to the way BASF streams are contained in the file, only one is supported. I have yet to see a BRP file with multiple. Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>