Mercurial > libavcodec.hg
comparison rv10.c @ 10558:16f0933d2c7f libavcodec
Make sure avcodec_set_dimensions() is used when rv20 changes resolution.
This should fix lowres resolution changes.
author | michael |
---|---|
date | Mon, 23 Nov 2009 19:22:19 +0000 |
parents | 46f8d58fbdfb |
children | 93b8130bf480 |
comparison
equal
deleted
inserted
replaced
10557:f2f4d6fe3f6d | 10558:16f0933d2c7f |
---|---|
368 if(new_w != s->width || new_h != s->height){ | 368 if(new_w != s->width || new_h != s->height){ |
369 av_log(s->avctx, AV_LOG_DEBUG, "attempting to change resolution to %dx%d\n", new_w, new_h); | 369 av_log(s->avctx, AV_LOG_DEBUG, "attempting to change resolution to %dx%d\n", new_w, new_h); |
370 if (avcodec_check_dimensions(s->avctx, new_h, new_w) < 0) | 370 if (avcodec_check_dimensions(s->avctx, new_h, new_w) < 0) |
371 return -1; | 371 return -1; |
372 MPV_common_end(s); | 372 MPV_common_end(s); |
373 s->width = s->avctx->width = new_w; | 373 avcodec_set_dimensions(s->avctx, new_w, new_h); |
374 s->height = s->avctx->height= new_h; | 374 s->width = new_w; |
375 s->height = new_h; | |
375 if (MPV_common_init(s) < 0) | 376 if (MPV_common_init(s) < 0) |
376 return -1; | 377 return -1; |
377 } | 378 } |
378 | 379 |
379 if(s->avctx->debug & FF_DEBUG_PICT_INFO){ | 380 if(s->avctx->debug & FF_DEBUG_PICT_INFO){ |