[vlc-commits] png encoder: really compress

Rafaël Carré git at videolan.org
Wed Apr 23 16:33:44 CEST 2014


vlc | branch: master | Rafaël Carré <funman at videolan.org> | Wed Apr 23 16:33:00 2014 +0200| [5e1774355b665ede8c8a965b9c148fa1e9d367f4] | committer: Rafaël Carré

png encoder: really compress

return the encoded block size rather than the raw YUV size

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5e1774355b665ede8c8a965b9c148fa1e9d367f4
---

 modules/codec/png.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/codec/png.c b/modules/codec/png.c
index d03e15a..9d9f634 100644
--- a/modules/codec/png.c
+++ b/modules/codec/png.c
@@ -421,7 +421,7 @@ static block_t *EncodeBlock(encoder_t *p_enc, picture_t *p_pic)
 
     /* restore original buffer position */
     p_block->p_buffer = p_start;
-    p_block->i_buffer = i_start;
+    p_block->i_buffer = i_start - p_block->i_buffer;
 
     p_block->i_dts = p_block->i_pts = p_pic->date;
 



More information about the vlc-commits mailing list