utvideodec: Support ULH0 and ULH2 formats.

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
riff: Support ULH0 and ULH2 fourccs.

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
utvideodec: Set colorspace by codec_tag.

Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
configure: arm: Don't try to enable pic for shared libraries on win32

The object file format doesn't support PIC loads in ARM assembly,
there are no relocation types in PE/COFF that correspond to
BFD_RELOC_32_PCREL (R_ARM_REL32 in ELF).

Signed-off-by: Martin Storsjö <martin@martin.st>
configure: Don't explicitly disable PIC for windows targets

This reverts e08c946c6 and 05165c2f7a. The actual intention of
e08c946c6 was to fix shared library builds for arm/win32, which
can also be accomplished in other ways.

Disabling pic on those platforms broke inline assembly on cygwin/64
(since some inline assembly requires knowing whether we are building
as PIC or not), and might also break inline assembly on other
compilers on windows.

As a side-effect, this unfortunately brings back all the warnings
about PIC not having any effect on that platform.

Signed-off-by: Martin Storsjö <martin@martin.st>
configure: Don't add -fPIC on windows targets

This avoids warnings about this option not having any effect on
this platform.

We still want to enable the pic configure item for these platforms
(if detected via the compiler builtin define __PIC__) to get proper
inline assembly workarounds.

Signed-off-by: Martin Storsjö <martin@martin.st>
matroskadec: introduce resync function.

This allows handling matroska files with errors.
Fixes test4.mkv and test7.mkv from the official Matroska test suite,
and by extension Bugzilla #62.

Based on a patch by Reimar Doffinger <Reimar.Doeffinger@gmx.de>

Signed-off-by: Anton Khirnov <anton@khirnov.net>
lavc: use AVFrame API properly in pad_last_frame().

This also simplifies the code.
lavc: add a libwavpack encoder wrapper
g2meet: reset dimensions on header parsing errors
g2meet: more graceful cursor loading
g2meet: do not leak buffers
g2meet: Fix a typo in the height comparison

Signed-off-by: Martin Storsjö <martin@martin.st>
4xm: use the correct logging context
4xm: K&R formatting cosmetics
4xm: refactor fourxm_read_header

Split sound and video tag parsing in separate functions.
4xm: do not overread while parsing header

Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
4xm: fold last_picture lazy allocation in decode_p_frame
4xm: forward errors from decode_p_block

Partially mitigate out of memory writes.

Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
4xm: drop pointless assert

Make sure the value of wlog2 is always between 0 and 3.