[FFmpeg-cvslog] r18954 - trunk/libavcodec/libopenjpeg.c

jai_menon subversion
Tue May 26 18:59:05 CEST 2009


Author: jai_menon
Date: Tue May 26 18:59:05 2009
New Revision: 18954

Log:
Use dimensions stored in AVCodecContext instead of local variables.

Modified:
   trunk/libavcodec/libopenjpeg.c

Modified: trunk/libavcodec/libopenjpeg.c
==============================================================================
--- trunk/libavcodec/libopenjpeg.c	Tue May 26 07:00:51 2009	(r18953)
+++ trunk/libavcodec/libopenjpeg.c	Tue May 26 18:59:05 2009	(r18954)
@@ -144,10 +144,10 @@ static int libopenjpeg_decode_frame(AVCo
         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];



More information about the ffmpeg-cvslog mailing list