ffmpeg.git
6 years agoswscale: yuv2planeX 8bit >=sse2 functions need aligned stack on x86-32.
Martin Storsjö [Wed, 4 Jul 2012 04:11:23 +0000 (21:11 -0700)]
swscale: yuv2planeX 8bit >=sse2 functions need aligned stack on x86-32.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
6 years agovp8: loopfilter >=sse2 functions need aligned stack on x86-32.
Martin Storsjö [Wed, 4 Jul 2012 04:11:36 +0000 (21:11 -0700)]
vp8: loopfilter >=sse2 functions need aligned stack on x86-32.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
6 years agoamr: remove shift out of the AMR_BIT() macro.
Ronald S. Bultje [Wed, 4 Jul 2012 03:36:44 +0000 (20:36 -0700)]
amr: remove shift out of the AMR_BIT() macro.

MSVC doesn't like the offsetof(..) >> 1 construct, it interprets it as
a non-literal, thus causing use of this in static tables to fail
compilation.

6 years agodsputilenc: group yasm and inline asm function pointer assignment.
Ronald S. Bultje [Wed, 4 Jul 2012 04:00:05 +0000 (21:00 -0700)]
dsputilenc: group yasm and inline asm function pointer assignment.

6 years agomov: use forward declaration of a function instead of a table.
Ronald S. Bultje [Wed, 4 Jul 2012 03:49:49 +0000 (20:49 -0700)]
mov: use forward declaration of a function instead of a table.

MSVC gives a compile error on the tentative definition of
mov_default_parse_table[].

6 years agoClarify Doxygen comment for FF_API_* #defines.
Diego Biurrun [Tue, 3 Jul 2012 20:42:42 +0000 (22:42 +0200)]
Clarify Doxygen comment for FF_API_* #defines.

6 years agoconfigure: simplify get_version()
Diego Biurrun [Mon, 2 Jul 2012 21:04:09 +0000 (23:04 +0200)]
configure: simplify get_version()

All libs have version headers now, which allows hardcoding the path.

6 years agoCreate version.h headers for libraries that lack them
Diego Biurrun [Sun, 1 Jul 2012 09:51:30 +0000 (11:51 +0200)]
Create version.h headers for libraries that lack them

6 years agogitignore: Use full path instead of relative path to specify patterns
Diego Biurrun [Mon, 2 Jul 2012 20:49:42 +0000 (22:49 +0200)]
gitignore: Use full path instead of relative path to specify patterns

This avoids confusion from patterns meant to only match at the top
level matching files in subdirectories.

6 years agompegvideo: remove VLAs
Ronald S. Bultje [Sun, 24 Jun 2012 18:19:24 +0000 (21:19 +0300)]
mpegvideo: remove VLAs

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoAdd XTEA encryption support in libavutil
Samuel Pitoiset [Tue, 3 Jul 2012 13:53:16 +0000 (15:53 +0200)]
Add XTEA encryption support in libavutil

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoAdd Blowfish encryption support in libavutil
Samuel Pitoiset [Tue, 3 Jul 2012 13:45:27 +0000 (15:45 +0200)]
Add Blowfish encryption support in libavutil

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoeval: Add the isinf() function and tests for it
Martin Storsjö [Sun, 1 Jul 2012 13:11:23 +0000 (16:11 +0300)]
eval: Add the isinf() function and tests for it

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoflacdec: move lpc filter to flacdsp
Mans Rullgard [Mon, 2 Jul 2012 12:51:04 +0000 (13:51 +0100)]
flacdec: move lpc filter to flacdsp

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoflacdec: split off channel decorrelation as flacdsp
Mans Rullgard [Sun, 17 Jun 2012 14:10:40 +0000 (15:10 +0100)]
flacdec: split off channel decorrelation as flacdsp

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoavplay: Add an option for not limiting the input buffer size
Martin Storsjö [Tue, 3 Jul 2012 19:57:19 +0000 (22:57 +0300)]
avplay: Add an option for not limiting the input buffer size

For reading from normal files on disk, the queue limits for
demuxed data work fine, but for reading data from realtime
streams, they mean we're not reading from the input stream
at all once the queue limit has been reached. For TCP streams,
this means that writing to the socket from the peer side blocks
(potentially leading to the peer dropping data), and for UDP
streams it means that our kernel might drop data.

For some protocols/servers, the server initially sends a
large burst with data to fill client side buffers, but once
filled, we should keep reading to avoid dropping data.

For all realtime streams, it IMO makes sense to just buffer
as much as we get (rather in buffers in avplay.c than in
OS level buffers). With this option set, the input thread
should always be blocking waiting for more input data,
never sleeping waiting for the decoder to consume data.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoFATE: add a test for WMA cover art.
Anton Khirnov [Fri, 22 Jun 2012 17:02:06 +0000 (19:02 +0200)]
FATE: add a test for WMA cover art.

6 years agoFATE: add a test for apetag cover art
Anton Khirnov [Fri, 22 Jun 2012 11:16:18 +0000 (13:16 +0200)]
FATE: add a test for apetag cover art

6 years agoFATE: add a test for itunes cover art.
Anton Khirnov [Fri, 22 Jun 2012 05:24:45 +0000 (07:24 +0200)]
FATE: add a test for itunes cover art.

6 years agoflacdec: factor out code setting avctx->sample_fmt
Mans Rullgard [Mon, 2 Jul 2012 23:28:32 +0000 (00:28 +0100)]
flacdec: factor out code setting avctx->sample_fmt

6 years agoflac: make FLAC_CHMODE_* constants consecutive
Mans Rullgard [Sun, 17 Jun 2012 10:45:10 +0000 (11:45 +0100)]
flac: make FLAC_CHMODE_* constants consecutive

6 years agoflacdec: allocate sample buffers with av_malloc
Mans Rullgard [Mon, 2 Jul 2012 22:16:30 +0000 (23:16 +0100)]
flacdec: allocate sample buffers with av_malloc

The buffers are only allocated once, although it can happen from
any of a few different places, so there is no need to use realloc.
Using av_malloc() ensures they are aligned suitably for SIMD
optimisations.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoflacdec: remove curr_bps from FLACContext
Mans Rullgard [Mon, 2 Jul 2012 00:43:12 +0000 (01:43 +0100)]
flacdec: remove curr_bps from FLACContext

This value does not need to be persistent across calls.

6 years agofate: add flac encode/decode tests with various options
Mans Rullgard [Mon, 2 Jul 2012 15:07:42 +0000 (16:07 +0100)]
fate: add flac encode/decode tests with various options

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoflacenc: add option for forcing stereo decorrelation mode
Mans Rullgard [Mon, 2 Jul 2012 13:52:05 +0000 (14:52 +0100)]
flacenc: add option for forcing stereo decorrelation mode

This is mainly useful for testing.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoismindex: Verify that all bitrate variants match
Martin Storsjö [Tue, 3 Jul 2012 11:58:52 +0000 (14:58 +0300)]
ismindex: Verify that all bitrate variants match

In Smooth Streaming, the fragments are addressed by time, and
the manifest only stores one list of time offests for all streams,
so all streams need to have identical fragment offsets. Warn if
this isn't the case, so that the user can fix the files instead of
getting failures at runtime when the fragments can't be found.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoismindex: Properly report errors reading the MFRA atom
Martin Storsjö [Tue, 3 Jul 2012 11:18:58 +0000 (14:18 +0300)]
ismindex: Properly report errors reading the MFRA atom

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agocosmetics: Consistently use C-style comments with multiple inclusion guards
Diego Biurrun [Mon, 2 Jul 2012 08:17:07 +0000 (10:17 +0200)]
cosmetics: Consistently use C-style comments with multiple inclusion guards

6 years agoanm: fix a few Doxygen comments
Diego Biurrun [Mon, 2 Jul 2012 18:40:26 +0000 (20:40 +0200)]
anm: fix a few Doxygen comments

6 years agomisc typo and wording fixes
Diego Biurrun [Wed, 13 Jun 2012 09:41:12 +0000 (11:41 +0200)]
misc typo and wording fixes

6 years agoattributes: add av_noreturn
Reinhard Tartler [Sun, 1 Jul 2012 17:38:40 +0000 (19:38 +0200)]
attributes: add av_noreturn

Also use it in the declaration of the various exit_program
implementations in avtools.

inspired by a clang-scan report.

6 years agoattributes: drop pointless define guards
Reinhard Tartler [Sun, 1 Jul 2012 18:36:03 +0000 (20:36 +0200)]
attributes: drop pointless define guards

the av_-prefixed attributes must not be defined outside of this file

6 years agoconfigure: do not disable av_always_inline with --enable-small
Mans Rullgard [Sun, 1 Jul 2012 19:21:10 +0000 (20:21 +0100)]
configure: do not disable av_always_inline with --enable-small

Currently, --enable-small turns av_always_inline into plain inline,
which is more or less ignored by the compiler.  While the intent of
this is probably to reduce code size by avoiding some inlining, it
has more far-reaching effects.

We use av_always_inline in two situations:

1. The body of a function is smaller than the call overhead.
   Instances of these are abundant in libavutil, the bswap.h
   functions being good examples.

2. The function is a template relying on constant propagation
   through inlined calls for sane code generation.  These are
   often found in motion compensation code.

Both of these types of functions should be inlined even if targeting
small code size.

Although GCC has heuristics for detecting the first of these types,
it is not always reliable, especially when the function uses inline
assembler, which is often the reason for having those functions in
the first place, so making it explicit is generally a good idea.

The size increase from inlining template-type functions is usually
much smaller than it seems due to different branches being mutually
exclusive between the different invocations.  The dead branches can,
however, only be removed after inlining and constant propagation have
been performed, which means the initial cost estimate for inlining
these is much higher than is actually the case, resulting in GCC
often making bad choices if left to its own devices.

Furthermore, the GCC inliner limits how much it allows a function to
grow due to automatic inlining of calls, and this appears to not take
call overhead into account.  When nested inlining is used, the limit
may be hit before the innermost level is reached.  In some cases, this
has prevented inlining of type 1 functions as defined above, resulting
in significant performance loss.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoflvdec: initial stream switch support
Luca Barbato [Sun, 1 Jul 2012 21:01:00 +0000 (23:01 +0200)]
flvdec: initial stream switch support

Codec change midstream gets mapped to a separate stream.

6 years agoavplay: fix write on freed memory for rawvideo
Luca Barbato [Thu, 28 Jun 2012 18:55:04 +0000 (20:55 +0200)]
avplay: fix write on freed memory for rawvideo

Do not assume avpacket and the decoded frames are independent.

To be absolutely sure and not sprinkle av_free_packet around the code
the call had been placed before getting the frame and on the error path.

6 years agosnow: remove a VLA used for edge emulation
Ronald S. Bultje [Mon, 2 Jul 2012 07:39:54 +0000 (10:39 +0300)]
snow: remove a VLA used for edge emulation

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agox86: lavfi: fix gradfun/yadif build with mmx/sse disabled
Mans Rullgard [Mon, 2 Jul 2012 22:04:04 +0000 (23:04 +0100)]
x86: lavfi: fix gradfun/yadif build with mmx/sse disabled

These functions are defined conditionally so any uses need to have
preprocessor guards.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agosnow: remove the runs[] VLA.
Ronald S. Bultje [Sat, 30 Jun 2012 17:34:39 +0000 (10:34 -0700)]
snow: remove the runs[] VLA.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agosnow: Check mallocs at init
Martin Storsjö [Mon, 2 Jul 2012 07:39:25 +0000 (10:39 +0300)]
snow: Check mallocs at init

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoflacdec: remove redundant setting of avctx->sample_fmt
Mans Rullgard [Mon, 2 Jul 2012 12:49:13 +0000 (13:49 +0100)]
flacdec: remove redundant setting of avctx->sample_fmt

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoasfdec: read attached pictures.
Anton Khirnov [Thu, 21 Jun 2012 20:17:43 +0000 (22:17 +0200)]
asfdec: read attached pictures.

6 years agoapetag: reindent
Anton Khirnov [Thu, 21 Jun 2012 17:02:40 +0000 (19:02 +0200)]
apetag: reindent

6 years agoapetag: export attached covers as video streams.
Anton Khirnov [Tue, 26 Jun 2012 16:58:39 +0000 (18:58 +0200)]
apetag: export attached covers as video streams.

6 years agoapetag: fix the amount of data read from binary tags.
Anton Khirnov [Tue, 26 Jun 2012 16:54:00 +0000 (18:54 +0200)]
apetag: fix the amount of data read from binary tags.

Substract the filename size from the data size.

6 years agoapetag: make sure avio_get_str() doesn't read more than it should.
Anton Khirnov [Tue, 26 Jun 2012 16:49:04 +0000 (18:49 +0200)]
apetag: make sure avio_get_str() doesn't read more than it should.

6 years agomov: read itunes cover art.
Anton Khirnov [Thu, 21 Jun 2012 16:24:27 +0000 (18:24 +0200)]
mov: read itunes cover art.

6 years agosnow: remove VLA in mc_block()
Mans Rullgard [Sun, 1 Jul 2012 14:39:22 +0000 (15:39 +0100)]
snow: remove VLA in mc_block()

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agointfloat: Don't use designated initializers in the public headers
Ronald S. Bultje [Mon, 2 Jul 2012 07:22:30 +0000 (10:22 +0300)]
intfloat: Don't use designated initializers in the public headers

intfloat.h is a public header, and is now (since a1245d5ca) included
by mathematics.h, which many external callers include.

This fixes building third party applications that include
mathematics.h in a language that doesn't support designated
initalizers.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agosnow: remove a VLA.
Ronald S. Bultje [Fri, 15 Jun 2012 16:59:57 +0000 (09:59 -0700)]
snow: remove a VLA.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agodoc: Remind devs to check return values, especially for malloc() et al
Diego Biurrun [Sat, 30 Jun 2012 13:35:57 +0000 (15:35 +0200)]
doc: Remind devs to check return values, especially for malloc() et al

6 years agoMS ATC Screen (aka MSS3) decoder
Kostya Shishkov [Thu, 28 Jun 2012 19:18:23 +0000 (21:18 +0200)]
MS ATC Screen (aka MSS3) decoder

6 years agovf_yadif: move x86 init code to x86/yadif.c
Mans Rullgard [Sun, 1 Jul 2012 12:08:17 +0000 (13:08 +0100)]
vf_yadif: move x86 init code to x86/yadif.c

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agovf_gradfun: move x86 init code to x86/gradfun.c
Mans Rullgard [Sun, 1 Jul 2012 11:51:30 +0000 (12:51 +0100)]
vf_gradfun: move x86 init code to x86/gradfun.c

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoroqvideo: Remove a totally unused dspcontext
Martin Storsjö [Sun, 1 Jul 2012 20:46:28 +0000 (23:46 +0300)]
roqvideo: Remove a totally unused dspcontext

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agosmacker: remove some unused code
Mans Rullgard [Sun, 1 Jul 2012 13:56:16 +0000 (14:56 +0100)]
smacker: remove some unused code

This removes some code apparently left over from vlc reader
debugging.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agodsicin: remove dead assignment
Mans Rullgard [Sun, 1 Jul 2012 13:28:50 +0000 (14:28 +0100)]
dsicin: remove dead assignment

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoaacdec: remove dead assignment
Mans Rullgard [Sun, 1 Jul 2012 12:50:09 +0000 (13:50 +0100)]
aacdec: remove dead assignment

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agorl2: remove dead assignment
Mans Rullgard [Sun, 1 Jul 2012 12:43:44 +0000 (13:43 +0100)]
rl2: remove dead assignment

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoproresenc: make a variable local to the loop where it is used
Mans Rullgard [Sun, 1 Jul 2012 12:38:12 +0000 (13:38 +0100)]
proresenc: make a variable local to the loop where it is used

This moves the mbs_per_slice declaration inside the only loop
where it is used.  Fixes a dead assignment.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoalsdec: remove dead assignments
Mans Rullgard [Sun, 1 Jul 2012 12:36:30 +0000 (13:36 +0100)]
alsdec: remove dead assignments

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoopt/eval: Include mathematics.h for NAN/INFINITY
Martin Storsjö [Sat, 30 Jun 2012 15:49:33 +0000 (18:49 +0300)]
opt/eval: Include mathematics.h for NAN/INFINITY

These files use NAN/INFINITY but didn't include mathematics.h to get
the fallback definitions if the system lacks the macros.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agomathematics: Don't use division by zero in NAN/INFINITY macros
Ronald S. Bultje [Fri, 22 Jun 2012 10:05:21 +0000 (13:05 +0300)]
mathematics: Don't use division by zero in NAN/INFINITY macros

Some compilers, MSVC among them, don't recognize the divisions by
zero as meaning infinity/nan.

These macros should, according to the standard, expand to constant
expressions, but this shouldn't matter for our usage.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agowma: Lower the maximum number of channels to 2
Martin Storsjö [Sat, 30 Jun 2012 18:30:28 +0000 (21:30 +0300)]
wma: Lower the maximum number of channels to 2

ff_wma_init is used only by wmadec and wmaenc, and neither of them
can handle more than 2 channels.

This fixes crashes with invalid files.

Based on patch by Piotr Bandurski and Michael Niedermayer.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agox86: cpu: clean up check for cpuid instruction support
Mans Rullgard [Sun, 24 Jun 2012 11:29:28 +0000 (12:29 +0100)]
x86: cpu: clean up check for cpuid instruction support

This adds macros for accessing the EFLAGS register and uses
these instead of coding the entire check in inline asm.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoARM: generate position independent code to access data symbols
Mans Rullgard [Fri, 29 Jun 2012 12:35:08 +0000 (13:35 +0100)]
ARM: generate position independent code to access data symbols

This creates proper position independent code when accessing
data symbols if CONFIG_PIC is set.

References to external symbols should now use the movrelx macro.
Some additional code changes are required since this macro may
need a register to hold the GOT pointer.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agodsputilenc_mmx: split assignment of ff_sse16_sse2 to SSE2 section.
Ronald S. Bultje [Thu, 14 Jun 2012 22:05:10 +0000 (22:05 +0000)]
dsputilenc_mmx: split assignment of ff_sse16_sse2 to SSE2 section.

6 years agodnxhdenc: add space between function argument type and comment.
Ronald S. Bultje [Thu, 14 Jun 2012 22:57:26 +0000 (15:57 -0700)]
dnxhdenc: add space between function argument type and comment.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agox86: fmtconvert: add special asm for float_to_int16_interleave_misc_*
Ronald S. Bultje [Thu, 14 Jun 2012 14:03:08 +0000 (15:03 +0100)]
x86: fmtconvert: add special asm for float_to_int16_interleave_misc_*

This gets rid of a variable-length array and a for loop in C code.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoattributes: Add a definition of av_always_inline for MSVC
Ronald S. Bultje [Sun, 24 Jun 2012 17:57:14 +0000 (20:57 +0300)]
attributes: Add a definition of av_always_inline for MSVC

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agocmdutils: Pass the actual chosen encoder to filter_codec_opts
Martin Storsjö [Fri, 29 Jun 2012 22:28:02 +0000 (01:28 +0300)]
cmdutils: Pass the actual chosen encoder to filter_codec_opts

This allows passing the right options to encoders when there's more
than one encoder for a certain codec id.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoos_support: Add fallback definitions for stat flags
Ronald S. Bultje [Sun, 24 Jun 2012 18:21:07 +0000 (21:21 +0300)]
os_support: Add fallback definitions for stat flags

Mingw headers provide similar defines already (unconditional #defines,
without any #undef or #ifdef around it), while MSVC doesn't have
them.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoos_support: Rename the poll fallback function to ff_poll
Martin Storsjö [Mon, 25 Jun 2012 09:27:37 +0000 (12:27 +0300)]
os_support: Rename the poll fallback function to ff_poll

The fallback function is a non-static function, we shouldn't be
defining non-static functions outside of the proper ff/av prefix
namespaces.

This is especially important for a function like poll, which
other parties (other libraries, or executables linking these
libraries) also might provide similar but incompatible fallbacks for.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agonetwork: Check for struct pollfd
Martin Storsjö [Mon, 25 Jun 2012 09:08:44 +0000 (12:08 +0300)]
network: Check for struct pollfd

We need to include winsock2.h here, to make sure we have the
real pollfd struct definition, if one exists, before defining the
fallback poll function.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoos_support: Don't compare a negative number against socket descriptors
Martin Storsjö [Sun, 24 Jun 2012 19:36:37 +0000 (22:36 +0300)]
os_support: Don't compare a negative number against socket descriptors

The fds are unsigned integers in the windows definition of struct
sockfds. Due to this, the comparison if (fds[i].fd > n) was always
false.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoos_support: Include all the necessary headers for the win32 open function
Ronald S. Bultje [Sun, 24 Jun 2012 18:29:14 +0000 (21:29 +0300)]
os_support: Include all the necessary headers for the win32 open function

io.h is required for open and _wopen, and fcntl.h is required for
the O_CREAT flag. On mingw, fcntl.h is included by os_support.h (and
the mingw fcntl.h includes io.h), but include it explicitly here
since this implementation requires it.

Also move the #undef open up. open must not be defined to ff_win32_open
while including the headers that declare the open function. On mingw,
this happened in os_support.h before open was redirected.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agox86: vc1: fix and enable optimised loop filter
Mans Rullgard [Fri, 22 Jun 2012 20:40:28 +0000 (21:40 +0100)]
x86: vc1: fix and enable optimised loop filter

The problem is that the ssse3 psign instruction does the wrong
thing here.  Commit ea60dfe incorrectly removed a macro emulating
this instruction for pre-ssse3 code.  However, the emulation is
incorrect, and the code relies on the behaviour of the macro.
Specifically, the psign sets destination elements to zero where
the corresponding source element is zero, whereas the emulation
only negates destination elements where the source is negative.

Furthermore, the PSIGNW_MMX macro in x86util.asm is totally bogus,
which is why the original VC-1 code had an additional right shift
when using it.  Since the psign instruction cannot be used here,
skip all the macro hell and use the working instruction sequence
directly.

None of this was noticed due a stray return statement in
ff_vc1dsp_init_mmx() which meant that only the mmx version of the
loop filter was ever used (before being removed in ea60dfe).

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agofile: Only include unistd.h if it exists
Ronald S. Bultje [Sun, 24 Jun 2012 21:42:27 +0000 (00:42 +0300)]
file: Only include unistd.h if it exists

It is included for the open/read/write/close functions. On
MSVC, where this header does not exist, the same functions
are provided by io.h, which is already included.

On windows, these functions are provided by io.h. Make sure
io.h is included if it exists, regardless of the setmode
function.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agorandom_seed: Only read /dev/*random if we have unistd.h
Ronald S. Bultje [Sun, 24 Jun 2012 18:26:31 +0000 (21:26 +0300)]
random_seed: Only read /dev/*random if we have unistd.h

unistd.h is used for open/read/close, but if this header does not
exist, there's probably no use in trying to open /dev/*random
at all.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agodoc: Indicate that RTMPT is natively implemented in libavformat
Samuel Pitoiset [Fri, 29 Jun 2012 12:18:41 +0000 (14:18 +0200)]
doc: Indicate that RTMPT is natively implemented in libavformat

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agortpdec: Don't explicitly include unistd.h any longer
Ronald S. Bultje [Sun, 24 Jun 2012 18:05:21 +0000 (21:05 +0300)]
rtpdec: Don't explicitly include unistd.h any longer

unistd.h used to be required for gethostname. On windows, gethostname
is provided by winsock2.h. Now network.h includes both unistd.h and
winsock2.h if they exist.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoflv: add support for G.711
Damien Fetis [Thu, 28 Jun 2012 14:28:56 +0000 (16:28 +0200)]
flv: add support for G.711

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
6 years agodoc: git: Add checklist with test steps to perform before pushing
Diego Biurrun [Mon, 14 May 2012 15:08:00 +0000 (17:08 +0200)]
doc: git: Add checklist with test steps to perform before pushing

6 years agoflvenc: K&R formatting cosmetics
Luca Barbato [Wed, 27 Jun 2012 08:16:18 +0000 (10:16 +0200)]
flvenc: K&R formatting cosmetics

6 years agomovenc: Add channel layouts for PCM.
Alex Converse [Sat, 23 Jun 2012 23:57:56 +0000 (16:57 -0700)]
movenc: Add channel layouts for PCM.

6 years agomss1: validate number of changeable palette entries
Kostya Shishkov [Wed, 27 Jun 2012 08:11:19 +0000 (10:11 +0200)]
mss1: validate number of changeable palette entries

6 years agomss1: report palette changed when some additional colours were decoded
Kostya Shishkov [Wed, 27 Jun 2012 08:07:47 +0000 (10:07 +0200)]
mss1: report palette changed when some additional colours were decoded

6 years agox86: fft: replace call to memcpy by a loop
Christophe Gisquet [Tue, 26 Jun 2012 14:10:33 +0000 (16:10 +0200)]
x86: fft: replace call to memcpy by a loop

The function call was a mess to handle, and memcpy cannot make
the assumptions we do in the new code.

Tested on an IMC sample: 430c -> 370c.

Signed-off-by: Mans Rullgard <mans@mansr.com>
6 years agoudp: Support IGMPv3 source specific multicast and source blocking
Martin Storsjö [Thu, 21 Jun 2012 11:19:56 +0000 (14:19 +0300)]
udp: Support IGMPv3 source specific multicast and source blocking

Based on an original patch by Stephen D'Angelo <SDAngelo@evertz.com>.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agodxva2: include dxva.h if found
Ronald S. Bultje [Sun, 24 Jun 2012 10:17:13 +0000 (11:17 +0100)]
dxva2: include dxva.h if found

Apparently, some build environments require dxva.h even for dxva2,
while others lack this header entirely.  Including it conditionally
allows building in both cases.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agolibm: Provide fallback definitions for isnan() and isinf()
Martin Storsjö [Tue, 26 Jun 2012 16:22:12 +0000 (19:22 +0300)]
libm: Provide fallback definitions for isnan() and isinf()

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agotcp: Pass NULL as hostname to getaddrinfo if the string is empty
Jordi Ortiz [Tue, 26 Jun 2012 17:22:21 +0000 (19:22 +0200)]
tcp: Pass NULL as hostname to getaddrinfo if the string is empty

This gives you the proper v4 or v6 version of the "any address",
allowing receiving connections on any address on the machine.

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agotcp: Set AI_PASSIVE when the socket will be used for listening
Jordi Ortiz [Tue, 26 Jun 2012 17:21:11 +0000 (19:21 +0200)]
tcp: Set AI_PASSIVE when the socket will be used for listening

Signed-off-by: Martin Storsjö <martin@martin.st>
6 years agoavconv: add an assert to silence an uninitialized variable warning.
Anton Khirnov [Mon, 25 Jun 2012 11:19:51 +0000 (13:19 +0200)]
avconv: add an assert to silence an uninitialized variable warning.

The warning silenced was:
avconv.c: In function ‘opt_output_file’:
avconv.c:3380:21: warning: ‘meta_out’ may be used uninitialized in this function [-Wuninitialized]
avconv.c:3315:20: note: ‘meta_out’ was declared here

6 years agoavconv: shut up an uninitialized variable warning.
Anton Khirnov [Mon, 25 Jun 2012 11:16:57 +0000 (13:16 +0200)]
avconv: shut up an uninitialized variable warning.

The warning silenced was:
avconv.c: In function ‘configure_filtergraph’:
avconv.c:603:8: warning: ‘ist’ may be used uninitialized in this function [-Wuninitialized]
avconv.c:549:18: note: ‘ist’ was declared here

6 years agoavfiltergraph: shut up uninitialized variable warning.
Anton Khirnov [Mon, 25 Jun 2012 11:01:31 +0000 (13:01 +0200)]
avfiltergraph: shut up uninitialized variable warning.

The warning silenced was:
libavfilter/avfiltergraph.c: In function ‘avfilter_graph_config’:
libavfilter/avfiltergraph.c:500:13: warning: ‘best_idx’ may be used uninitialized in this function [-Wuninitialized]

6 years agoaf_join: initialize a variable to shut up gcc warning.
Anton Khirnov [Mon, 25 Jun 2012 10:57:16 +0000 (12:57 +0200)]
af_join: initialize a variable to shut up gcc warning.

The warning silenced was:
libavfilter/af_join.c: In function ‘join_request_frame’:
libavfilter/af_join.c:451:9: warning: ‘nb_samples’ may be used uninitialized in this function [-Wuninitialized]

6 years agoamix: fix format specifier for AVFilterLink.sample_rate.
Anton Khirnov [Mon, 25 Jun 2012 10:53:18 +0000 (12:53 +0200)]
amix: fix format specifier for AVFilterLink.sample_rate.

It is a plain int now.

6 years agolavfi: make filters less verbose.
Anton Khirnov [Mon, 25 Jun 2012 04:31:38 +0000 (06:31 +0200)]
lavfi: make filters less verbose.

6 years agompc8: read APE tags.
Anton Khirnov [Fri, 22 Jun 2012 18:48:40 +0000 (20:48 +0200)]
mpc8: read APE tags.

6 years agolavr: x86: fix ff_conv_fltp_to_flt_6ch function prototypes
Justin Ruggles [Wed, 2 May 2012 20:44:54 +0000 (16:44 -0400)]
lavr: x86: fix ff_conv_fltp_to_flt_6ch function prototypes

Changed to match the number of parameters in conv_func_interleave(), which is
how they are called. The change isn't strictly necessary because the 4th
parameter is not used, but the code is clearer if they match.