Commit Graph

47446 Commits

Author SHA1 Message Date
Stefano Sabatini
c9ff32215b lavu/opt: allow to set sample and pixel format with av_opt_set_int()
This change requires the user to specify min and max value, and makes
possible to prevent the user to set AV_{SAMPLE,PIX}_FMT_NONE if
forbidden.

Add required ifdeffery in case of mixed libraries, when libavutil is
updated but not the other libraries.

This is a followup of 08d0969c14.
2012-12-01 19:33:30 +01:00
Michael Niedermayer
b5cedf8b66 fate/mp3: increase fuzz for NEON, due to different rounding from lrintf()
This should fix fate failures of the hecommon test

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 17:15:57 +01:00
Stefano Sabatini
13c39e9676 lavfi/geq: add T variable and example 2012-12-01 16:05:15 +01:00
Michael Niedermayer
5473f6258c Merge remote-tracking branch 'qatar/master'
* qatar/master:
  configure: Use headers in the check for _beginthreadex for w32threads
  avutil: Use a configure check to enable windows console functions
  avutil: Include io.h with a separate condition from windows console functions

Conflicts:
	libavutil/log.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 13:10:48 +01:00
Stefano Sabatini
12cd992d67 doc/ffmpeg-filters: add short description 2012-12-01 13:06:56 +01:00
Michael Niedermayer
13d351bd45 tests/ref/seek/lavf_gif: update for 9d5cfce855: gifdec: rudimentary seeking
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 12:56:12 +01:00
Paul B Mahol
9d5cfce855 gifdec: rudimentary seeking
With this ffplay -loop X successfully seeks to start.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 11:43:50 +00:00
Paul B Mahol
2152b60f39 gifdec: use av_fast_malloc()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:53:22 +00:00
Paul B Mahol
6b11ae7112 shorten: return more meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:17:50 +00:00
Paul B Mahol
e4af8ed8c7 ws-snd1: return meaningful error code
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:17:45 +00:00
Paul B Mahol
679c7578a6 wnv1: return more meaningful error codes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:17:20 +00:00
Paul B Mahol
51bcf8ac85 xldec: K&R formatting cosmetics
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:17:20 +00:00
Paul B Mahol
24e5cb4836 xldec: return meaningful error code
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 10:17:16 +00:00
Paul B Mahol
3b56ed3478 motionpixels: use meaningful error code
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 09:18:21 +00:00
Paul B Mahol
b912895d94 mvi: check av_mallocz() result
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-12-01 09:06:24 +00:00
Michael Niedermayer
822d10e7c5 swscale: fix 12 and 14 bit YUV planar output with scaling.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 03:41:24 +01:00
Michael Niedermayer
f0695b09dd pcmdec: check codec_id
Fixes out of array accesses

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 02:36:28 +01:00
Michael Niedermayer
b90e795f73 check std tag size before reading.
Fixes out of array read

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 00:30:11 +01:00
Michael Niedermayer
a7ee6281f7 qdm2: check array index before use, fix out of array accesses
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-01 00:00:08 +01:00
Michael Niedermayer
991e23519a aacps: check iid/icc_par more completely.
Fixes global out of array read.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 22:23:49 +01:00
Michael Niedermayer
7205e896a1 dxa: check reference frame availability before use.
Fix NULL pointer dereference

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 22:23:49 +01:00
Paul B Mahol
daede25f0b update Changelog
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 16:52:37 +00:00
Paul B Mahol
57b00d7ab1 gifdec: remove width and height from demuxer context
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 16:09:02 +00:00
Michael Niedermayer
2c69fcc2ff smacker: more complete vlc length check, fixes out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 16:14:18 +01:00
Michael Niedermayer
50cbe09d8c smacker: check smacker_decode_tree() return value
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 16:14:18 +01:00
Paul B Mahol
d56b15017a undo file modifiers that suck in
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 15:00:35 +00:00
Martin Storsjö
3bbe63d1a4 configure: Use headers in the check for _beginthreadex for w32threads
When targeting the metro API subset, this function still exists in
the link libraries, but is excluded from the headers. This makes
sure w32threads is automatically disabled when targeting this API
subset (since not all the necessary functions for it are available).

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-11-30 16:57:02 +02:00
Martin Storsjö
7e6a11bcf7 avutil: Use a configure check to enable windows console functions
Not all versions or API subsets of windows have these functions.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-11-30 16:56:57 +02:00
Martin Storsjö
b70abd5b61 avutil: Include io.h with a separate condition from windows console functions
Not all versions of windows have the console color functions,
while io.h might be needed for isatty (which can be found in
unistd.h or io.h).

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-11-30 16:56:54 +02:00
Vitaliy E Sugrobov
f83657fcf6 Add exception for "gif" in image2 probe() method.
Without this exception files with ".gif" extension by default
recognized as input suitable for image2 demuxer rather than gif.
In order to pass image through gif demuxer it was necessary
to use -f gif option.
This change affected 'make fate' test results because previously
image2 demuxer and gif decoder took only first frame of multiframe
test data, which is no longer true with gif demuxer.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:35:11 +00:00
Vitaliy E Sugrobov
5603b2bf6e Gif demuxer
Gif demuxer is capable of extracting multiple frames from gif file.
In conjunction with gif decoder it implements support for reading
animated gifs.
Demuxer has two options available to user: default_delay and min_delay.
These options are for protection from too rapid gif animations. In practice
it is standard approach to slow down rendering of this kind of gifs. If you try to
play gif with delay between frames of one hundredth of second (100fps) using
one of major web browsers, you get significantly slower playback,
around 10 fps. This is because browser detects that delay value is less than some
threshold (usually 2 hundredths of second) and reset it to default value (usually 10
hundredths of second, which corresponds to 10fps). Manipulating these options user
can achieve the same effect during conversion to some video format. Otherwise user
can set them to not protect from rapid animations at all.
The other case when these options necessary is for gif images encoded according to
gif87a standard since prior to gif89a there was no delay information included in file.
Bump lavf minor version.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:33:58 +00:00
Vitaliy E Sugrobov
005cb97e3e Move some definitions to header file.
Share them with upcoming demuxer module.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:33:58 +00:00
Vitaliy E Sugrobov
de0cb7f070 Additional checks to prevent overread.
Check for availability of some required amount of bytes in buffer before
reading further.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:33:58 +00:00
Vitaliy E Sugrobov
91499f4ee8 Prepare gif decoder for use in conjunction with gif demuxer.
Add capability of reading multiple frames instead of only first.
Implement support for different gif frame 'disposal methods'.
Add option that allows to change background color resulting from
conversion of gif with transparency to any other format which
not support it.
Also bump lavc minor version.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:33:58 +00:00
Vitaliy E Sugrobov
c5fe41c768 Add meaningful error codes and constants.
Replace literals with named constants in several pieces of code
like 'return -1' and 'case 0xab'.
Change the way decoder handles absence of image data in a file:
notify gif_decode_frame() caller with got_picture set to zero
instead of returning -1.

Signed-off-by: Vitaliy E Sugrobov <vsugrob@hotmail.com>
2012-11-30 14:33:58 +00:00
Michael Niedermayer
034a1afbd8 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  avutil: Include io.h with a separate condition from MapViewOfFile
  cmdutils: Use a configure check for enabling CommandLineToArgvW

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 14:55:12 +01:00
Michael Niedermayer
db29a7c7c2 Merge commit '9d46eaec7a90bd8f5cd9e45398c6d17804182320'
* commit '9d46eaec7a90bd8f5cd9e45398c6d17804182320':
  build: The FLAC encoder also depends on the flacdsp code
  img2: K&R formatting cosmetics
  h264: check context state before decoding slice data partitions
  flashsv: make sure data for zlib priming is available

Conflicts:
	libavcodec/Makefile
	libavformat/img2.c
	libavformat/img2dec.c
	libavformat/img2enc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 14:49:13 +01:00
Clément Bœsch
8119d8b01f configure: add lavfi avr dep to .pc when required. 2012-11-30 14:19:14 +01:00
Paul B Mahol
d4c59f77b6 adpcm/thp: cosmetics: reindent
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 10:48:37 +00:00
Paul B Mahol
1560c3295d iff: fix some incorrect interpretations of invalid files
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 10:44:00 +00:00
Paul B Mahol
50b5c2296a iff: MAUD support
Based on patch by Piotr Bandurski
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-30 10:34:55 +00:00
Carl Eugen Hoyos
ccf771cd79 Correctly skip strf tag for subtitles when decoding avi.
Fixes ticket #1797.
2012-11-30 10:18:37 +01:00
Michael Niedermayer
d9bec3b6a2 lavc: fix duplicate stats_out line.
Found-by: Thierry Foucu
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 05:31:41 +01:00
Michael Niedermayer
bc16031a41 mjpegdec: print error message when quant_index is invalid
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 04:17:03 +01:00
Michael Niedermayer
a2f680c7bc mjpegdec: check h/v_count, fix context becoming inconsistent and causing out of array accesses.
This also fixes a long standing comment in the code.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-30 04:17:03 +01:00
Stefano Sabatini
08d0969c14 lavu/opt: change the way default pixel and sample format value is set
Use the i64 field rather than the string value. Using a string to set a
default sample/pixel format is weird, also the new interface is more
consistent with the rest of the API.

This is technically an API break, but hopefully there are no applications
using this feature outside of FFmpeg. In order to save backward
compatibility with mixed libraries in case libavutil is updated but not
the other libraries, some ifdeffery hacks are added.

Note that the version check is only performed when class->version != 0,
since if it is not defined then we assume that no version was defined and
the class is not affected by the change.

We will luckily get rid of the hack at the next major bump.
2012-11-30 00:01:53 +01:00
Michael Niedermayer
0b28abf903 vble: check packet size.
Fixes null pointer dereference

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-29 23:12:42 +01:00
Michael Niedermayer
10416a4d56 id3v2: check index against buffer size. Fix out of array access
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-11-29 23:12:42 +01:00
Piotr Bandurski
0b14c197f1 iff: mention all decoders 2012-11-29 19:16:10 +00:00
Paul B Mahol
9a31997938 BRSTM demuxer
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2012-11-29 19:04:35 +00:00