]> git.sesse.net Git - vlc/commitdiff
* mpga: fixed. (using es_out_Send with PES)
authorLaurent Aimar <fenrir@videolan.org>
Fri, 21 Nov 2003 16:07:20 +0000 (16:07 +0000)
committerLaurent Aimar <fenrir@videolan.org>
Fri, 21 Nov 2003 16:07:20 +0000 (16:07 +0000)
modules/demux/mpeg/mpga.c

index ca40e28d3aa70765d04b062d83643dc4e8b80cf6..d0212d1ddfd4e38d1c36b485e9f0e26ca79029ad 100644 (file)
@@ -2,7 +2,7 @@
  * mpga.c : MPEG-I/II Audio input module for vlc
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: mpga.c,v 1.9 2003/11/16 22:54:12 gbazin Exp $
+ * $Id: mpga.c,v 1.10 2003/11/21 16:07:20 fenrir Exp $
  *
  * Authors: Laurent Aimar <fenrir@via.ecp.fr>
  *
@@ -342,7 +342,7 @@ error:
 static int Demux( input_thread_t * p_input )
 {
     demux_sys_t  *p_sys = p_input->p_demux_data;
-    pes_packet_t *p_pes;
+    block_t      *p_frame;
 
     uint32_t     header;
     uint8_t      *p_peek;
@@ -389,19 +389,19 @@ static int Demux( input_thread_t * p_input )
                           p_input->stream.p_selected_program,
                           p_sys->i_time * 9 / 100 );
 
-    if( ( p_pes = stream_PesPacket( p_input->s, mpga_frame_size( header ) ) )
-                                                                      == NULL )
+    if( ( p_frame = stream_Block( p_input->s, mpga_frame_size( header ) ) ) == NULL )
     {
         msg_Warn( p_input, "cannot read data" );
         return 0;
     }
 
-    p_pes->i_dts =
-    p_pes->i_pts = input_ClockGetTS( p_input,
-                                     p_input->stream.p_selected_program,
-                                     p_sys->i_time * 9 / 100 );
+    p_frame->i_dts =
+    p_frame->i_pts =
+        input_ClockGetTS( p_input,
+                          p_input->stream.p_selected_program,
+                          p_sys->i_time * 9 / 100 );
 
-    es_out_Send( p_input->p_es_out, p_sys->p_es, p_pes );
+    es_out_Send( p_input->p_es_out, p_sys->p_es, p_frame );
 
     p_sys->i_time += (mtime_t)1000000 *
                      (mtime_t)mpga_frame_samples( header ) /