[vlc-devel] commit: Fixed h264 aspect ratio overflow. (Laurent Aimar )

git version control git at videolan.org
Fri Aug 22 01:52:56 CEST 2008


vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Fri Aug 22 01:54:31 2008 +0200| [2fb4aa1b9304477dc5c37e1b884db03819b2159d] | committer: Laurent Aimar 

Fixed h264 aspect ratio overflow.

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

 modules/packetizer/h264.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/modules/packetizer/h264.c b/modules/packetizer/h264.c
index 78e354b..c6b2255 100644
--- a/modules/packetizer/h264.c
+++ b/modules/packetizer/h264.c
@@ -886,8 +886,9 @@ static void PutSPS( decoder_t *p_dec, block_t *p_frag )
                 w = 0;
                 h = 0;
             }
+
             if( h != 0 )
-                p_dec->fmt_out.video.i_aspect = VOUT_ASPECT_FACTOR *
+                p_dec->fmt_out.video.i_aspect = (int64_t)VOUT_ASPECT_FACTOR *
                         ( w * p_dec->fmt_out.video.i_width ) /
                         ( h * p_dec->fmt_out.video.i_height);
             else




More information about the vlc-devel mailing list