changeset 9714:5df11d49abb7 libavcodec

Use dimensions stored in AVCodecContext instead of local variables.
author jai_menon
date Tue, 26 May 2009 16:59:05 +0000
parents d762f9979193
children 997d2de9cd84
files libopenjpeg.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/libopenjpeg.c	Tue May 26 05:00:51 2009 +0000
+++ b/libopenjpeg.c	Tue May 26 16:59:05 2009 +0000
@@ -144,10 +144,10 @@
         adjust[x] = FFMAX(image->comps[x].prec - 8, 0);
     }
 
-    for(y = 0; y < height; y++) {
-        index = y*width;
+    for(y = 0; y < avctx->height; y++) {
+        index = y*avctx->width;
         img_ptr = picture->data[0] + y*picture->linesize[0];
-        for(x = 0; x < width; x++, index++) {
+        for(x = 0; x < avctx->width; x++, index++) {
             *img_ptr++ = image->comps[0].data[index] >> adjust[0];
             if(image->numcomps > 2 && check_image_attributes(image)) {
                 *img_ptr++ = image->comps[1].data[index] >> adjust[1];