build: utvideoenc: Add missing dependency on Huffman code
build: eamad: Add missing dependency on mpegvideo code
h264: Remove an assert on current_picture_ptr being null

It is possible in various error paths as well as gap handling
that this has already been allocated. It is not clear why that
would be a problem with the current code, thus disable the
assert to avoid a common assert failure when asserts are enabled.

Signed-off-by: Martin Storsjö <martin@martin.st>
parser: Don't use pc as context for av_dlog

The ParserContext class doesn't have an AVClass, required for
using it as a logging class.

Signed-off-by: Martin Storsjö <martin@martin.st>
build: disable ranlib on mingw

Using ranlib is not required but prevents using the libraries with
msvc.

Signed-off-by: Mans Rullgard <mans@mansr.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
configure: add section for libc-specific hacks

Signed-off-by: Martin Storsjö <martin@martin.st>
dsputil: workaround __VA_ARGS__ missing tokenization for MSVC

A second expansion forces the preprocessor to tokenize properly.

Signed-off-by: Martin Storsjö <martin@martin.st>
lavu: add snprintf(), vsnprint() and strtod() replacements for MS runtime.

Signed-off-by: Martin Storsjö <martin@martin.st>
configure: Add support for MSVC cl.exe/link.exe

Signed-off-by: Martin Storsjö <martin@martin.st>
avopt: fix examples to match the same style about default values as the actual code.

Signed-off-by: Martin Storsjö <martin@martin.st>
x86: vp56: cmov version of vp56_rac_get_prob requires inline asm

Signed-off-by: Diego Biurrun <diego@biurrun.de>
configure: Disable some warnings in MSVC

This disables the following warnings:
C4100: unreferenced formal parameter
 (1035 occurrances)
C4214: nonstandard extension used : bit field types other than int
 (609 occurances)
C4996: 'avpriv_snprintf': This function or variable may be unsafe.
       Consider using _snprintf_s instead. To disable deprecation,
       use _CRT_SECURE_NO_WARNINGS. See online help for details.
 (351 occurrances)

Signed-off-by: Martin Storsjö <martin@martin.st>
x86: dsputil: Do not redundantly check for CPU caps before calling init funcs

The init functions check for CPU capabilities on their own already.
fate: Allow setting the ld parameter from the config file

Signed-off-by: Martin Storsjö <martin@martin.st>
configure: Set the right cc_e flags for msvc

The default ones work, but outputs the preprocessed file on stdout
(into config.log).

Signed-off-by: Martin Storsjö <martin@martin.st>
mpegvideo: set AVFrame fields to NULL after freeing the base memory

Prevents dangling pointers and makes access after free more obvious.
Setting AVFrame.qscale_table to NULL is required for successfully
allocating a previously freed Picture with ff_alloc_picture().
mss2: do not try to read too many palette entries

Reported by Michael Niedermayer <michaelni@gmx.at>

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
mss12: avoid unnecessary division in arith*_get_bit()

That division can be replaced with a comparison:
((c->value - c->low) << 1) + 1 >= range

By expanding 'range' definition and simplifying this inequation we obtain
the final expression.

Suggested by Michael Niedermayer <michaelni@gmx.at>

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
mss2: simplify loop in decode_rle()

It calculates the sum of power of two series, which can be done in one step.

Suggested by Michael Niedermayer <michaelni@gmx.at>

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
af_asyncts: check return value from lavr when flushing.

Fixes an infinite loop on flush when avresample_get_delay() still
reports some samples but avresample_convert() doesn't return any data.