Commit Graph

10990 Commits

Author SHA1 Message Date
Alexander Strasser
3245be95ac lavf/segment: Rename variable in print_csv_escaped_str()
Rename a local variable to make the code more self-explanatory.

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-09-15 22:58:11 +02:00
Alexander Strasser
bac1b31bf6 lavf/segment: Simplify CSV field quoting code
Should also be faster (though I doubt that hardly ever matters
for the usage here).

Also remove the pointer copy. Since we do not need to reset the
pointer to the start of the string, it is not needed anymore.

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-09-15 22:55:21 +02:00
Andrey Utkin
aefed6ca87 udp: pick params from AVOptions also
This updated version does not deviate from previous behavior on default value of 'buffer_size'

I skipped porting 'sources', 'block' options for now as they're parsed seriously. So i added TODO remarks.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-15 22:13:21 +02:00
Michael Niedermayer
f1ca40ee00 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  riff: Add SVQ3 fourcc
  fate: ac3: add 4.0 and downmix tests
  configure: x86: improve ebp availability check
  vorbisdec: ensure FASTDIV denominator is never 1
  avformat: refactor avformat_close_input
  avformat: simplify avformat_close_input

Conflicts:
	configure
	libavcodec/vorbisdec.c
	libavformat/utils.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-15 10:35:26 +02:00
Derek Buitenhuis
1c56cdad33 riff: Add SVQ3 fourcc
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2012-09-14 14:12:52 -04:00
Derek Buitenhuis
fef412a24d riff: Add SVQ3 fourcc
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-14 19:48:45 +02:00
Michael Niedermayer
e2d643efcd lavf/compute_pkt_fields: only run pts by duration correction if reference ts is available
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-14 19:47:41 +02:00
Luca Barbato
44272c1ccc avformat: refactor avformat_close_input
Do not crash if the input format is not allocated yet.
2012-09-14 14:26:27 +02:00
Luca Barbato
4d1f443c3d avformat: simplify avformat_close_input
avio_close checks by itself for NULL condition.
2012-09-14 14:26:27 +02:00
Michael Niedermayer
062091f87f compute_pkt_fields2: dont interpret max_b_frames of <0 as there being b frames.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-14 02:30:00 +02:00
Michael Niedermayer
bc3d5173cc libavformat.v: export ffurl_protocol_next
This is used by avidemux, and is likely usefull to others too.

Patch by: gruntster (Avidemux Rev 7990 — 2012-05-30 13:02:27)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-13 16:21:25 +02:00
Michael Niedermayer
e3e09f2bad Merge remote-tracking branch 'qatar/master'
* qatar/master:
  os_support: Choose between direct.h and io.h using a configure check
  os_support: Include io.h instead of direct.h on mingw32ce
  x86: ac3dsp: Only refer to the ac3_downmix_sse symbol if it has been declared
  swscale: Remove two bogus asserts
  ac3: move ac3_downmix() from dsputil to ac3dsp
  lavr/audio_mix_matrix: acknowledge the existence of LFE2.
  mlp_parser: avoid mapping multiple disctinct TrueHD channels to the same Libav channel.
  lavu/audioconvert: add a second low frequency channel.

Conflicts:
	doc/APIchanges
	libavcodec/ac3dsp.c
	libavcodec/ac3dsp.h
	libavcodec/mlp_parser.c
	libavutil/audioconvert.c
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-13 15:35:50 +02:00
Michael Niedermayer
c942e8b1d7 Merge commit '07584eaf4a95db3f11d3bc411f9786932829e82b'
* commit '07584eaf4a95db3f11d3bc411f9786932829e82b':
  mpegts: check substreams before discarding
  Add a smooth streaming segmenter muxer
  file: Add an avoption for disabling truncating existing files on open
  img2dec: always close AVIOContexts
  rtpdec_jpeg: Error out on other unsupported type values as well
  rtpdec_jpeg: Disallow using the reserved q values
  rtpdec_jpeg: Fold the default qtables case into an existing if statement
  rtpdec_jpeg: Store and reuse old qtables for q values 128-254
  rtpdec_jpeg: Simplify the calculation of the number of qtables
  rtpdec_jpeg: Add more comments about the fields in the SOF0 section
  rtpdec_jpeg: Clarify where the subsampling magic numbers come from
  rtpdec_jpeg: Don't use a bitstream writer for the EOI marker
  rtpdec_jpeg: Don't needlessly use a bitstream writer for the header
  rtpdec_jpeg: Simplify writing of the jpeg header
  rtpdec_jpeg: Merge two if statements
  rtpdec_jpeg: Write the DHT section properly

Conflicts:
	libavformat/Makefile
	libavformat/allformats.c
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-13 15:22:16 +02:00
Martin Storsjö
ca6b544ac9 os_support: Choose between direct.h and io.h using a configure check
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-13 14:56:54 +03:00
Martin Storsjö
7b07fab567 os_support: Include io.h instead of direct.h on mingw32ce
Windows CE doesn't have neither mkdir nor _mkdir officially (only
CreateDirectoryW), but mingw32ce has compat wrappers with these names
(declared in io.h since direct.h is unavailable).

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-13 13:52:50 +03:00
Christian Schmidt
07584eaf4a mpegts: check substreams before discarding
Allow to extract the AC3 core from TrueHD with the "copy" codec.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2012-09-12 23:43:53 +02:00
Martin Storsjö
62c9ae11a7 Add a smooth streaming segmenter muxer
This muxer splits the output from the ismv muxer into individual
files, in realtime.

The same can also be done by the standalone tool ismindex, but this
muxer is needed for doing it in realtime (especially for live
streams that need extra handling for updating the lookahead fields
in the fragment headers).

Using this muxer, one can deliver live smooth streaming from a
normal static file web server. (Using ismindex, one can deliver
premade smooth streaming files from a static file web server,
or prepare files for serving with IIS.)

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 23:42:16 +03:00
Martin Storsjö
29a9b12b10 file: Add an avoption for disabling truncating existing files on open
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 23:42:09 +03:00
Michael Niedermayer
2de8877689 asfdec: invert SAR
It appears this was wrong

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-12 20:35:09 +02:00
Tomas Härdin
5e3572893d img2dec: always close AVIOContexts
Zero sized files would cause the contexts to leak away.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2012-09-12 14:31:09 +02:00
Carl Eugen Hoyos
7680d99b43 Fix muxing mjpeg in swf. 2012-09-12 13:08:27 +02:00
Martin Storsjö
c3bcd22ed3 rtpdec_jpeg: Error out on other unsupported type values as well
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:10:56 +03:00
Martin Storsjö
1743938df1 rtpdec_jpeg: Disallow using the reserved q values
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:10:45 +03:00
Martin Storsjö
1de9317bd0 rtpdec_jpeg: Fold the default qtables case into an existing if statement
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:10:32 +03:00
Martin Storsjö
a218deb856 rtpdec_jpeg: Store and reuse old qtables for q values 128-254
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:10:05 +03:00
Martin Storsjö
a252649059 rtpdec_jpeg: Simplify the calculation of the number of qtables
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:09:57 +03:00
Martin Storsjö
cbaa9eeda3 rtpdec_jpeg: Add more comments about the fields in the SOF0 section
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:09:30 +03:00
Martin Storsjö
31adff08a1 rtpdec_jpeg: Clarify where the subsampling magic numbers come from
Write out the numbers the way they are constructed, not just the
final values.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:09:21 +03:00
Martin Storsjö
c64d2a63df rtpdec_jpeg: Don't use a bitstream writer for the EOI marker
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:09:02 +03:00
Martin Storsjö
20f325f320 rtpdec_jpeg: Don't needlessly use a bitstream writer for the header
Everything written with this bitstream writer is 8/16 bit units
(except for a pair of 4 bit values), so using a bitstream writer
isn't necessary.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:08:33 +03:00
Martin Storsjö
43957fcc71 rtpdec_jpeg: Simplify writing of the jpeg header
Generalize writing of any number of qtables. Don't manually write
16 bit values in two separate calls.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:08:09 +03:00
Martin Storsjö
932d8300d3 rtpdec_jpeg: Merge two if statements
This makes the code more readable and robust.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:07:57 +03:00
Martin Storsjö
7ef4323405 rtpdec_jpeg: Write the DHT section properly
Currently the size header of the generated DHT section is
incorrect, making the mjpeg decoder just skip it. Since the
written huffman tables are the default ones, this failure had
gone undetected.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-12 12:07:29 +03:00
Michael Niedermayer
23e9e5c7d9 rtmpproto: reorder some expressions to fix compilation with clang without optimizations
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-12 05:17:52 +02:00
Stefano Sabatini
e592fd0ed1 lavf/flvenc: convert commented debug log to an av_dlog call
Also add some additional info (DTS and DTS time).
2012-09-11 18:58:19 +02:00
Michael Niedermayer
ec7946853a Merge remote-tracking branch 'qatar/master'
* qatar/master:
  rtpdec_jpeg: Add support for default quantizers
  x86: dsputil: Move specific optimization settings out of global init function
  avplay: get rid of ugly casts in the options table
  avplay: fix prototypes for option callbacks.
  flvdec: always set AVFMTCTX_NOHEADER.
  file: Use a normal private context for storing the file descriptor
  configure: Adjust the xgetbv instrinsic check
  configure: Add --disable-inline-asm command line option
  configure: Don't try to enable the log2 function on msvcrt

Conflicts:
	configure
	ffplay.c
	libavcodec/x86/dsputil_mmx.c
	libavformat/file.c
	libavformat/flvdec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-11 15:24:22 +02:00
Samuel Pitoiset
55e778bebd rtpdec_jpeg: Add support for default quantizers
Generate quantization tables when they are not present in the
first chunk.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-11 11:53:08 +03:00
Anton Khirnov
ee0dadc109 flvdec: always set AVFMTCTX_NOHEADER.
New streams may be created at any time, e.g. on codec change.
2012-09-11 09:13:29 +02:00
Michael Niedermayer
8470e6c96f lavf/avformat_seek_file: fix harmless integer overflow
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-11 03:02:51 +02:00
Stefano Sabatini
00d516454c lavf/segment: add segment_list_flags option
Allow to specify options affecting the segment list generation.

In particular: add +live and +cache flags.

For a full discussion read trac ticket #1642:
http://ffmpeg.org/trac/ffmpeg/ticket/1642

Also add live M3U8 generation example.
2012-09-11 01:24:54 +02:00
Michael Niedermayer
b3b27b63a0 mpegtsenc: add forgotten ()
Fixes integer overflow

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 20:57:23 +02:00
Martin Storsjö
0697d81269 file: Use a normal private context for storing the file descriptor
Previously the file descriptor was stored in the priv_data pointer.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-10 19:49:41 +03:00
Sébastien Brochet
e14725cecc add OTF support for attachments
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 17:08:18 +02:00
Michael Niedermayer
41dba453f9 utils/update_stream_timings: fix division by zero
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 16:57:31 +02:00
Michael Niedermayer
108957c661 avidec/guess_ni_flag: fix harmless integer overflow
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 16:56:59 +02:00
Michael Niedermayer
b422e2c58a compute_pkt_fields: fix harmless integer overflow
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 16:15:07 +02:00
Michael Niedermayer
bff2afb3e9 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  x86: dsputil: Only compile motion_est code when encoders are enabled
  mem: fix typo in check for __ICC
  fate: mp3: drop redundant CMP setting
  rtp: Depacketization of JPEG (RFC 2435)
  Rename ff_put_string to avpriv_put_string
  mjpeg: Rename some symbols to avpriv_* instead of ff_*
  yadif: cosmetics

Conflicts:
	Changelog
	libavcodec/mjpegenc.c
	libavcodec/x86/Makefile
	libavfilter/vf_yadif.c
	libavformat/version.h
	libavutil/mem.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-10 14:06:20 +02:00
Samuel Pitoiset
3c19815416 rtp: Depacketization of JPEG (RFC 2435)
Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-09 22:22:21 +03:00
Derek Buitenhuis
16c03f2e91 file: Add S_ISFIFO compatability macro
Not all systems have S_ISFIFO.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-09 20:23:14 +02:00
Michael Niedermayer
07108cafc6 gxfenc: assert that the to be written data has not been truncated.
Otherwise out of array reads would happen later

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-09 14:31:44 +02:00