Andreas Rheinhardt
ae937c4902
avcodec/aac_ac3_parser: Untangle AAC and AC3 parsing error codes
...
Also remove the (unused) AAC_AC3_PARSE_ERROR_CHANNEL_CFG while at it;
furthermore, fix the documentation of ff_ac3_parse_header()
and (ff|avpriv)_adts_header_parse().
Reviewed-by: Andrew Sayers <ffmpeg-devel@pileofstuff.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
7 months ago
James Almer
4c35bb53f9
avcodec/ac3_parser: improve false positive detection when parsing sync frames
...
A two byte sync word is not enough to ensure we got a real syncframe, nor are
all the range checks we do in the first seven bytes. Do therefore an integrity
check for the sync frame in order to prevent the parser from filling avctx with
bogus information.
Signed-off-by: James Almer <jamrial@gmail.com>
2 years ago
James Almer
b5abf6fdfc
avcodec/aac_ac3_parser: don't fill stream info in the sync function
...
Have it only find frame boundaries. The stream props will then be filled once
we have an assembled frame.
Signed-off-by: James Almer <jamrial@gmail.com>
2 years ago
Alexander Strasser
ecd71916d1
lavc/aac_ac3_parser: fix potential overflow when averaging bitrate
...
The new code is analog to how it's done in our mpegaudio parser.
Acked-by: Jun Zhao <barryjzhao@tencent.com>
Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
4 years ago
Jun Zhao
60d79b1df9
lavc/aac_ac3_parser: improve the raw AAC file bit rate calculation
...
Now we just use one ADTS raw frame to calculate the bit rate, it's
lead to a larger error when get the duration from bit rate, the
improvement cumulate Nth ADTS frames to get the average bit rate.
e,g used the command get the duration like:
ffprobe -show_entries format=duration -i fate-suite/aac/foo.aac
before this improvement dump the duration=2.173935
after this improvement dump the duration=1.979267
in fact, the real duration can be get by command like:
ffmpeg -i fate-suite/aac/foo.aac -f null /dev/null with time=00:00:01.97
Also update the fate-adtstoasc_ticket3715.
Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
5 years ago
Luca Barbato
6258d362b8
ac3: Do not clash with normal AVERROR
...
The parsing function return AVERROR and AAC_AC3_PARSE_ERROR values,
make sure they are not misunderstood.
12 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
13 years ago
Mans Rullgard
cc276c85d1
Make channel layout masks unsigned
...
It makes more sense for a bit mask to use an unsigned type.
The change should be source and binary compatible on all
supported systems, hence micro version bump.
Fixes a few invalid shifts.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Justin Ruggles
be18738801
Get audio_service_type for AC-3 based on bitstream mode in the AC-3 parser
...
and decoder, and vice-versa for the AC-3 encoder.
14 years ago
Mans Rullgard
2912e87a6c
Replace FFmpeg with Libav in licence headers
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Justin Ruggles
bfeca7beb6
Add channel layout support to the AC-3 decoder and AC-3 parser.
...
Originally committed as revision 18622 to svn://svn.ffmpeg.org/ffmpeg/trunk
16 years ago
Joakim Plate
4cff8dc88f
Allow AC-3 parser to modify codec_id.
...
Patch by Joakim Plate (elupus A ecce D se).
Originally committed as revision 17447 to svn://svn.ffmpeg.org/ffmpeg/trunk
16 years ago
Diego Biurrun
406792e7b0
cosmetics: Remove pointless period after copyright statement non-sentences.
...
Originally committed as revision 16684 to svn://svn.ffmpeg.org/ffmpeg/trunk
16 years ago
Alex Converse
11d6f38cc9
Factorise enum of AC3 error types to be usable by AAC in the ADTS patch that
...
will follow
Patch by Alex Converse ( alex converse gmail com )
Originally committed as revision 16479 to svn://svn.ffmpeg.org/ffmpeg/trunk
16 years ago
Stefano Sabatini
987903826b
Globally rename the header inclusion guard names.
...
Consistently apply this rule: the guard name is obtained from the
filename by stripping the leading "lib", converting '/' and '.' to
'_' and uppercasing the resulting name. Guard names in the root
directory have to be prefixed by "FFMPEG_".
Originally committed as revision 15120 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Justin Ruggles
14b7062829
cosmetics: make all references to AC-3 capitalized and hyphenated
...
Originally committed as revision 14523 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
David Liu
7694a7d93f
Close parse context.
...
Patch by David LIU david liu st com
Originally committed as revision 13962 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Måns Rullgård
7c43009358
add necessary #includes in headers
...
Originally committed as revision 13043 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Michael Niedermayer
133ac890fb
Add new_frame_start and need_next_header.
...
based on a patch by Bartlomiej
Originally committed as revision 12895 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Michael Niedermayer
454064ad1e
Change aac and ac3 parsers to use ff_combine_frame().
...
Originally committed as revision 12894 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Michael Niedermayer
8c731c9743
remove AACAC3FrameFlag
...
Originally committed as revision 12888 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Bartlomiej Wolowiec
469d8816d6
undo changes in aac_ac3_parser
...
Originally committed as revision 12778 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Bartlomiej Wolowiec
c09ed33e18
Corrections of errors in aac_ac3_parser
...
Originally committed as revision 12759 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Bartlomiej Wolowiec
0a5754c3b7
change of aac_ac3_parser, so it is able to send complete portion of data to decoder
...
Originally committed as revision 12758 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Bartlomiej Wolowiec
be1e2a2bfa
removal of stream_type in AACAC3ParseContext and adding AACAC3FrameFlag
...
Originally committed as revision 12622 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Bartlomiej Wolowiec
4e6eeaf019
using stream type in eac3 parser
...
Originally committed as revision 12570 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Justin Ruggles
c599e297e7
Pass AACAC3ParseContext to sync() instead of individual arguments. Patch by
...
Bartlomiej Wolowiec (bartek wolowiec gmail com)
Originally committed as revision 12564 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Diego Biurrun
5b21bdabe4
Add FFMPEG_ prefix to all multiple inclusion guards.
...
Originally committed as revision 10765 to svn://svn.ffmpeg.org/ffmpeg/trunk
17 years ago
Måns Rullgård
99545457bf
include all prerequisites in header files
...
Originally committed as revision 9344 to svn://svn.ffmpeg.org/ffmpeg/trunk
18 years ago
Aurelien Jacobs
679c2294cb
cosmetics: rename for consistency after previous aac and ac3 parsers move
...
Originally committed as revision 8942 to svn://svn.ffmpeg.org/ffmpeg/trunk
18 years ago
Aurelien Jacobs
99ff31dc75
move aac and ac3 parsers in their own files
...
Originally committed as revision 8941 to svn://svn.ffmpeg.org/ffmpeg/trunk
18 years ago
Diego Biurrun
b78e7197a8
Change license headers to say 'FFmpeg' instead of 'this program/this library'
...
and fix GPL/LGPL version mismatches.
Originally committed as revision 6577 to svn://svn.ffmpeg.org/ffmpeg/trunk
18 years ago
Diego Biurrun
04d7f60143
Add official LGPL license headers to the files that were missing them.
...
Originally committed as revision 6219 to svn://svn.ffmpeg.org/ffmpeg/trunk
19 years ago
Måns Rullgård
9d9f4119bd
move common stuff from avienc.c and wav.c to new file riff.c
...
Originally committed as revision 5720 to svn://svn.ffmpeg.org/ffmpeg/trunk
19 years ago
Diego Biurrun
bb270c0896
COSMETICS: tabs --> spaces, some prettyprinting
...
Originally committed as revision 4764 to svn://svn.ffmpeg.org/ffmpeg/trunk
19 years ago
Diego Biurrun
115329f160
COSMETICS: Remove all trailing whitespace.
...
Originally committed as revision 4749 to svn://svn.ffmpeg.org/ffmpeg/trunk
19 years ago
Fabrice Bellard
155e9ee909
initial seek support
...
Originally committed as revision 2502 to svn://svn.ffmpeg.org/ffmpeg/trunk
21 years ago
Fabrice Bellard
4358d5def3
removed ctype.h header
...
Originally committed as revision 2225 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Zdenek Kabelac
546031ee86
* keeping compiler happy and quiet
...
Originally committed as revision 1817 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Zdenek Kabelac
5d23497493
* more strict types
...
Originally committed as revision 1815 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Roman Shaposhnik
e738cee9c4
Complete support for OpenDML AVIs and AVIs > 2Gb.
...
Originally committed as revision 1814 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Roman Shaposhnik
ce9fce63c5
AVI > 2Gb (OpenDML) generation patch by (Roman Shaposhnick <rvs at sun dot com>)
...
Originally committed as revision 1741 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Roman Shaposhnik
2e7973bbe7
correct AUDIO strf parsing patch by (Roman Shaposhnick <rvs at sun dot com>)
...
Originally committed as revision 1664 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Fabrice Bellard
abac617591
renamed libav to libavformat
...
Originally committed as revision 1276 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Zdenek Kabelac
c18a2692d2
* cleanup statics & const
...
Originally committed as revision 1186 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Philip Gladstone
2727c35ed7
* Made encoding to ASF streams work again. It turns out that the default
...
stream id that AVI wants for MSMPEG4V3 doesn't work for ASF. I have
added a flag to indicate that certain tags should not be used in ASF
streams. I think that this is the wrong solution (just adding a flag
for ASF), but it does work.
Originally committed as revision 1112 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Fabrice Bellard
e095026ab4
unified wav header parsing - added extradata support
...
Originally committed as revision 1092 to svn://svn.ffmpeg.org/ffmpeg/trunk
22 years ago
Fabrice Bellard
c9a65ca8c3
converted to new API
...
Originally committed as revision 547 to svn://svn.ffmpeg.org/ffmpeg/trunk
23 years ago
Zdenek Kabelac
4606ac8dee
* some minor modification by Philip Gladston
...
* grab containes new code
Originally committed as revision 388 to svn://svn.ffmpeg.org/ffmpeg/trunk
23 years ago
Zdenek Kabelac
a266644f56
* more warning cleanups
...
* adding const & statics
Originally committed as revision 387 to svn://svn.ffmpeg.org/ffmpeg/trunk
23 years ago