]> git.sesse.net Git - vlc/commitdiff
png: encoder: encode visible lines, but use pitch for offset
authorTristan Matthews <tmatth@videolan.org>
Sat, 11 Oct 2014 04:09:21 +0000 (00:09 -0400)
committerTristan Matthews <tmatth@videolan.org>
Sat, 11 Oct 2014 04:09:21 +0000 (00:09 -0400)
modules/codec/png.c

index 781bacfbd1a81bc953f7c981549df01fda7bcc40..33f75155b9a8f8feec30445aafc3dc26854e5f78 100644 (file)
@@ -407,7 +407,7 @@ static block_t *EncodeBlock(encoder_t *p_enc, picture_t *p_pic)
 
     for( int i = 0; i < p_pic->p->i_visible_lines; i++ )
     {
-        png_write_row( p_png, p_pic->p->p_pixels + (i * p_pic->p->i_visible_pitch) );
+        png_write_row( p_png, p_pic->p->p_pixels + (i * p_pic->p->i_pitch) );
         if( p_sys->b_error ) goto error;
     }