Andreas Cadhalpun
72211a2af0
asfenc: fix leaking asf->index_ptr on error
...
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
10 years ago
Andreas Cadhalpun
2c8cff2be4
asfenc: fix leaking asf->index_ptr on error
...
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Diego Biurrun
daf8cf358a
avformat: Don't anonymously typedef structs
10 years ago
Paul B Mahol
12c5addebc
avformat/asfenc: remove unneeded #include, there are no assert() only av_assert*
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Michael Niedermayer
4b45aa517c
avformat/asfenc: replace != 0 error check by <0
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
1cf28fd5f3
avformat/asfenc: Make asf_write_indexs index argument const
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Aaron Graham
72dcd48c19
avformat/asfenc: honor the maximum of 63 payloads
...
Fixes Ticket3634
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Anton Khirnov
6072184e70
asfenc: use codec descriptors instead of AVCodecs to write codec info
...
Also, stop using AVCodecContext.codec_name as fallback, since it will be
deprecated.
Changes the result of the lavf-asf test (and its associated seektest),
since 'msmpeg4v3' gets written instead of just 'msmpeg4'.
11 years ago
Daniel Verkamp
5e7d21c7ad
ff_put_wav_header: add flag to force WAVEFORMATEX
...
Partially undoes commit 2c4e08d89327595f7f4be57dda4b3775e1198d5e:
riff: always generate a proper WAVEFORMATEX structure in
ff_put_wav_header
A new flag, FF_PUT_WAV_HEADER_FORCE_WAVEFORMATEX, is added to force the
use of WAVEFORMATEX rather than PCMWAVEFORMAT even for PCM codecs.
This flag is used in the Matroska muxer (the cause of the original
change) and in the ASF muxer, because the specifications for
these formats indicate explicitly that WAVEFORMATEX should be used.
Muxers for other formats will return to the original behavior of writing
PCMWAVEFORMAT when writing a header for raw PCM.
In particular, this causes raw PCM in WAV to generate the canonical
44-byte header expected by some tools.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Carl Eugen Hoyos
eeee59ba4d
Never write 0 as maximum bitrate for asf files.
...
WMP refuses to play such streams.
11 years ago
Michael Niedermayer
369cdf917a
avformat/asfenc: dont allow non interleaved packets
...
The muxer does not support this currently
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Carl Eugen Hoyos
a3bd33af9e
Write sample_aspect_ratio to asf files.
...
Fixes ticket #3528 .
11 years ago
Carl Eugen Hoyos
862174ec83
Move GUID-related objects to riffenc.c and riff.c.
...
This simplifies the following eac3-in-wav patch.
11 years ago
Peter Ross
fcbb94712d
riffenc: add option to ff_put_bmp_header to ignore extradata
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Vladimir Pantelic
bb461370e3
asfenc: mux chapters in ASF files using an ASF "marker" section
...
ASF markers only have a start time, so we lose the chapter end times,
but that is ASF for you
Signed-off-by: Vladimir Pantelic <vladoman@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
11 years ago
Vladimir Pantelic
09f3c937ed
asfenc: remember send time and offset of the index entries
...
Signed-off-by: Vladimir Pantelic <vladoman@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
11 years ago
Vladimir Pantelic
c53b5dda35
asfdec: replace magic constant with DATA_HEADER_SIZE
...
Signed-off-by: Vladimir Pantelic <vladoman@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
11 years ago
Chih-Wei Huang
985920433c
avformat/asfenc: fix a build error
...
It's introduced by the erroneous merging commit cbe47b1e
.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Michael Niedermayer
2175f76894
avformat/asfenc: use av_freep() for extra saftey
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
11 years ago
Alexandra Khirnova
f369b9356c
avformat: Use av_reallocp_array() where suitable
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
11 years ago
Michael Niedermayer
38665efcc7
asfenc: convert asserts to av_assert
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
3cd93cc7b8
Revert "asfenc: return error on negative timestamp"
...
This reverts commit d1bec33b46
, it breaks
FATE.
12 years ago
Luca Barbato
d1bec33b46
asfenc: return error on negative timestamp
...
According to the specification the timestamp is represented by a 32bit
unsigned.
CC: libav-stable@libav.org
12 years ago
Diego Biurrun
48a4ffa722
asf: K&R formatting cosmetics
12 years ago
Michael Niedermayer
b4c753487c
asfenc: avoid negative timestamps
...
Fixes Ticket1606
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
3b4bb19e63
lavf: flush the output AVIOContext in av_write_trailer().
...
This is consistent with stdio and is what we want to do in all cases.
Fixes a bug in the voc muxer which didn't flush in write_trailer()
previously. This is the cause of the change in the test results.
12 years ago
Mans Rullgard
987170cb9d
dict: add av_dict_count()
...
This adds a function to retrieve the number of entries in a
dictionary and updates the places directly accessing what should
be an opaque struct to use this new function instead.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
13 years ago
Diego Biurrun
0177b7d23a
Improve descriptiveness of a number of codec and container long names
13 years ago
Ronald S. Bultje
fd48721849
lavf: use conditional notation for default codec in muxer declarations.
...
This removes the use of macro nesting in these code constructs, which
makes it easier to parse in pre-processors.
13 years ago
Martin Storsjö
20234a4bd7
cosmetics: Align muxer/demuxer declarations
...
Also add missing trailing commas, break long codec_tag lines and
add spaces in codec_tag declarations.
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Ramiro Polla
bd603494f9
asfenc: properly write index information
...
The index must take into account the pre-roll time and must seek backwards,
not forwards.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ramiro Polla
ae315a6a38
asfenc: start at object 1 instead of 0
...
This is how it is done in the official muxer.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ramiro Polla
bc13b74992
asfenc: remove useless casts
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ramiro Polla
f2fad251b8
asfenc: reduce code duplication with new variable
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ramiro Polla
1ceff0859d
asfenc: rename some variables
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ramiro Polla
97d36a1898
asfenc: realloc index_ptr fewer times
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Anton Khirnov
c3f9ebf743
lavf: make av_set_pts_info private.
...
It's supposed to be called only from (de)muxers.
13 years ago
ami_stuff
ef4f403159
Never use MP3 as default audio codec for asf.
...
Some Windows versions do not ship an appropriate MP3 decoder.
13 years ago
ami_stuff
e2adce3b8e
asfenc: Use wmav2 audio codec by default.
13 years ago
Peter Ross
b7c9512fca
asfenc: rename put_guid to ff_put_guid
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
John Brooks
2c4e08d893
riff: always generate a proper WAVEFORMATEX structure in ff_put_wav_header
...
The cbSize field should be included in all cases, even with PCM where
its value is ignored.
Fixes encoding PCM audio in Matroska for some players which insist on
a full WAVEFORMATEX structure for A_MS/ACM audio.
Since fate uses wav files for the audio test a larger number of tests
has changed checksums or shifted positions due to the 2 byte longer
wave header.
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
13 years ago
Carl Eugen Hoyos
d9b6068764
Use WMAv2 as default audio codec for asf.
13 years ago
Carl Eugen Hoyos
3bcbd8c5c7
Use M4S2 as default video tag for MPEG-4 ASP in asf.
13 years ago
Chiranjeevi Melam
8096b7c67f
asfenc: fix assert failure on long ffserver runs
14 years ago
Anton Khirnov
dfc2c4d900
lavf: use designated initialisers for all (de)muxers.
...
It's more readable and less prone to breakage.
14 years ago
Anton Khirnov
d2d67e424f
Remove all uses of now deprecated metadata functions.
14 years ago
Anton Khirnov
6dc7d80de7
avio: avio_ prefix for url_close_dyn_buf
14 years ago
Anton Khirnov
b92c545282
avio: avio_ prefix for url_open_dyn_buf
14 years ago
Anton Khirnov
8978fedaee
avio: introduce an AVIOContext.seekable field
...
Use it instead of url_is_streamed and AVIOContext.is_streamed.
14 years ago