Michael Niedermayer
d8246d475c
vc1dec: mark by assert that the default path cannot occur
...
Fixes CID703827, CID703828
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Hendrik Leppkes
33f2a49423
vc1: only disable interlaced b-frames for software decoding
...
Tested-by: Gwenole Beauchesne <gb.devel@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Hendrik Leppkes
b87ff34496
vc1: implement vc1 field interlaced dxva2 decoding
...
Tested-by: Gwenole Beauchesne <gb.devel@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Mashiat Sarker Shakkhar
35a35d49d2
Double motion vector range for HPEL interlaced picture in proper place
...
The existing code is not in the right place and it should cover both
interlaced frame and field pictures.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
12 years ago
Mashiat Sarker Shakkhar
eb657ecefd
vc1dec: Set opposite to the correct value for 1REF field pictures
...
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
12 years ago
Mashiat Sarker Shakkhar
7cc3c4e1d4
vc1dec: Invoke edge emulation regardless of MV precision for 1-MV chroma
...
This is required due to the way VC-1 handles chroma pull-back which may end
up causing negative chroma MV for zero luma MV. Edge emulation needs to be
invoked in such cases.
This only affects vertical component of chroma motion vector.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
12 years ago
Mashiat Sarker Shakkhar
88058d9a99
vc1dec: Set chroma reference field from REFFIELD for 1REF field pictures
...
Interlaced field pictures can have one or two reference pictures, signaled
by NUMREF syntax element. For single reference pictures, reference picture
is determined by REFFIELD syntax element.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
12 years ago
Mashiat Sarker Shakkhar
7fb35ee931
vc1dec: Use correct spelling of "opposite"
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
12 years ago
Janne Grunau
6f8ef5320f
vc1dec: prevent memory leak in error path
...
Fixes CID732271.
12 years ago
Janne Grunau
714f5ab597
vc1dec: prevent memory leak on av_realloc error
12 years ago
Anton Khirnov
716d413c13
Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat
12 years ago
Diego Biurrun
1218777ffd
avcodec: Convert some commented-out printf/av_log instances to av_dlog
12 years ago
Kostya Shishkov
4dc8c8386e
vc1dec: add flush function for WMV9 and VC-1 decoders
...
CC: libav-stable@libav.org
12 years ago
Alberto Delmás
ee769c6a7c
MSS2 decoder
...
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Kostya Shishkov
7627c35a81
vc1: export some functions
...
This is a preparatory step for the MSS2 decoder which needs to use
the WMV9 decoder to decode some kinds of frames.
From the patch by Alberto Delmás <adelmas@gmail.com>
12 years ago
Michael Niedermayer
15e4bd65b1
vc1dec: support debug & FF_DEBUG_PICT_INFO.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
12 years ago
Mashiat Sarker Shakkhar
9cc74c9f6e
vc1dec: Remove separate scaling function for interlaced field MVs
...
The scaling process for obtaining direct MVs from co-located field MVs
is the same for interlaced field and progressive pictures.
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Mashiat Sarker Shakkhar
8379ea5e9f
vc1dec: Invoke edge_emulation regardless of MV precision
...
In VC-1 interlaced field pictures, chroma motion vectors can extend beyond
picture boundary even if luma vectors are bounded. The problem shows up
only for hpel interpolated MVs, and may be due to the way motion vectors
are scaled / cropped.
Thanks to Konstantin Shishkov for suggesting the fix. This fixes
long-known segfaults in MC-VC1.ts from videolan streams archive.
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Mans Rullgard
cfb1091898
vc1dec: remove useless #include simple_idct.h
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Nicolas George
cc7eff1fa0
vc1dec: count ENDOFSEQ code in return value.
12 years ago
Michael Niedermayer
45838561f2
vc1dec: Override invalid macroblock quantizer
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Michael Niedermayer
2bf369b60c
vc1: avoid reading beyond the last line in vc1_draw_sprites()
...
Fixes overread
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Michael Niedermayer
1100acbab2
vc1dec: check that coded slice positions and interlacing match.
...
This fixes out of array writes
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Michael Niedermayer
0aa907cfb1
vc1dec: Do not ignore ff_vc1_parse_frame_header_adv return value
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
12 years ago
Michael Niedermayer
22ce78a95e
vc1dec: dont apply the loop filter on fields
...
Fixes read of uninitialized memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
697edcc12a
vc1dec: dont attempt error concealment on field pictures.
...
This is not implemented and doesnt work.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Mashiat Sarker Shakkhar
082829520e
vc1dec: Do not use random pred_flag if motion vector data is skipped
...
This fixes SA10143.vc1 from test-suite. Also partially fixes MC-VC1.ts
from videolan streams archive.
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Hendrik Leppkes
14ac47fcc7
vc1: signal interlaced and tff flag to the consumer
...
Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Reviewed-by: Mashiat Sarker Shakkhar <mashiat.sarker@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
5e59a77cec
vc1dec: check that coded slice positions and interlacing match.
...
This fixes out of array writes
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
e985cfd18b
vc1dec: check end_mb_y / start_mb_y validity
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Martin Storsjö
00c3b67b8a
cosmetics: Align codec declarations
...
Also break some long lines, remove codec function placeholder comments
and add spaces in sample/pixel format lists.
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Michael Niedermayer
a60a4d7041
vc1dec: Fix global array overread.
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
1acc553e54
vc1dec: dont ignore ff_vc1_parse_frame_header_advs return value
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
e3bd61248f
vc1dec: avoid == -1 checks for errors.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
b378a23395
vc1dec: sanity check state used in get_mvdata_interlaced()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Mashiat Sarker Shakkhar
95b192de5d
vc1: Do not read from array if index is invalid.
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
13 years ago
Michael Niedermayer
d6eef545c1
vc1dec: move mquant zero check down.
...
This way it catches all cases, and prevents later segfaults.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Lou Logan
2d38081b4f
cosmetics: fix some typos
...
Patch attached.
From 2d4094fc0dcb4ccd0735eb7e1719e228ebb56bb9 Mon Sep 17 00:00:00 2001
From: Lou Logan <lou@lrcd.com>
Date: Mon, 12 Mar 2012 14:13:44 -0800
Subject: [PATCH] cosmetics: fix some typos
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
105cac3407
vc1dec: Fix vc1 decoding with --disable-optimizations.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Diego Biurrun
3c715383ea
vc1: Move init code shared between decoder and parser to common code file.
...
This fixes standalone compilation of the VC-1 parser.
13 years ago
Michael Niedermayer
64c58f1436
vc1: mquant is not allowed to be 0
...
Fixes out of bounds read.
Checked against SMPTE 421M-2006
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Diego Biurrun
324deaa268
Replace AVFrame pointer type punning by proper struct member assignments.
13 years ago
Michael Niedermayer
75d11b55d7
vc1: avoid reading beyond the last line in vc1_draw_sprites()
...
Fixes overread
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Ronald S. Bultje
c742ab4e81
vc1parse: call vc1_init_common().
...
The parser uses VLC tables initialized in vc1_common_init(), therefore
we should call this function on parser init also.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
13 years ago
Ronald S. Bultje
ae591aeea5
vc1: prevent using last_frame as a reference for I/P first frame.
...
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
13 years ago
Martin Storsjö
efd29844eb
mpegvideo: Add ff_ prefix to nonstatic functions
...
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Martin Storsjö
5f2c159c0f
vc1: Add ff_ prefix to nonstatic symbols
...
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Martin Storsjö
1fec055066
msmpeg4: Add ff_ prefixes to nonstatic symbols
...
Signed-off-by: Martin Storsjö <martin@martin.st>
13 years ago
Janne Grunau
510ef04a46
vc1: prevent null pointer dereference on broken files
...
CC: libav-stable@libav.org
13 years ago