summaryrefslogtreecommitdiff
path: root/libavcodec/dvdec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-04-22 21:37:54 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-04-22 22:26:55 +0200
commit70d54392f5015b9c6594fcae558f59f952501e3b (patch)
treebf8188c68474cebf9982c80cfe6244b3d4347f23 /libavcodec/dvdec.c
parent92ef4be4ab9fbb7d901b22e0036a4ca90b00a476 (diff)
lowres2 support.
The new lowres support is limited to decoders where lowres decoding is possible in high quality. I was not able to measure any speed difference, but if one is found the 2-3 lines that might affect speed can be made compile time conditional Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/dvdec.c')
-rw-r--r--libavcodec/dvdec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/dvdec.c b/libavcodec/dvdec.c
index f0fa5e9023..4e09d0dd9a 100644
--- a/libavcodec/dvdec.c
+++ b/libavcodec/dvdec.c
@@ -144,7 +144,7 @@ static int dv_decode_video_segment(AVCodecContext *avctx, void *arg)
LOCAL_ALIGNED_16(DCTELEM, sblock, [5*DV_MAX_BPM], [64]);
LOCAL_ALIGNED_16(uint8_t, mb_bit_buffer, [ 80 + FF_INPUT_BUFFER_PADDING_SIZE]); /* allow some slack */
LOCAL_ALIGNED_16(uint8_t, vs_bit_buffer, [5*80 + FF_INPUT_BUFFER_PADDING_SIZE]); /* allow some slack */
- const int log2_blocksize = 3;
+ const int log2_blocksize = 3-s->avctx->lowres;
int is_field_mode[5];
assert((((int)mb_bit_buffer) & 7) == 0);
@@ -382,5 +382,6 @@ AVCodec ff_dvvideo_decoder = {
.close = dvvideo_close,
.decode = dvvideo_decode_frame,
.capabilities = CODEC_CAP_DR1 | CODEC_CAP_SLICE_THREADS,
+ .max_lowres = 3,
.long_name = NULL_IF_CONFIG_SMALL("DV (Digital Video)"),
};