fixed byte order in swf_JPEG2TagToImage().
[swftools.git] / lib / modules / swfbits.c
index b92b06b..11aac11 100644 (file)
@@ -332,9 +332,9 @@ RGBA* swf_JPEG2TagToImage(TAG*tag, int*width, int*height)
         int x;
         jpeg_read_scanlines(&cinfo,&to,1);
         for(x=cinfo.output_width-1;x>=0;--x) {
-            int b = to[x*3+0];
+            int r = to[x*3+0];
             int g = to[x*3+1];
-            int r = to[x*3+2];
+            int b = to[x*3+2];
             line[x].r = r;
             line[x].g = g;
             line[x].b = b;