[vlc-commits] demux: h26x: set demux fps to packetizer

Francois Cartegnie git at videolan.org
Mon Mar 20 18:50:59 CET 2017


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Mar 20 18:49:00 2017 +0100| [9a506a0a43a92049253e92e9caeaa0b264b98a43] | committer: Francois Cartegnie

demux: h26x: set demux fps to packetizer

otherwise computed dts/pts will always be incorrect if no vui

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

 modules/demux/mpeg/h26x.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/demux/mpeg/h26x.c b/modules/demux/mpeg/h26x.c
index 5872832..3d94f64 100644
--- a/modules/demux/mpeg/h26x.c
+++ b/modules/demux/mpeg/h26x.c
@@ -352,6 +352,8 @@ static int GenericOpen( demux_t *p_demux, const char *psz_module,
 
     /* Load the mpegvideo packetizer */
     es_format_Init( &fmt, VIDEO_ES, i_codec );
+    fmt.video.i_frame_rate = p_sys->dts.i_divider_num;
+    fmt.video.i_frame_rate_base = p_sys->dts.i_divider_den;
     p_sys->p_packetizer = demux_PacketizerNew( p_demux, &fmt, psz_module );
     if( !p_sys->p_packetizer )
     {



More information about the vlc-commits mailing list