Commit cdf5edf7 authored by Gildas Bazin's avatar Gildas Bazin

* modules/demux/ogg.c: we now set p_input->stream.i_mux_rate.
parent 6d6601ea
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* ogg.c : ogg stream input module for vlc * ogg.c : ogg stream input module for vlc
***************************************************************************** *****************************************************************************
* Copyright (C) 2001 VideoLAN * Copyright (C) 2001 VideoLAN
* $Id: ogg.c,v 1.1 2002/10/24 09:30:48 gbazin Exp $ * $Id: ogg.c,v 1.2 2002/10/27 16:59:30 gbazin Exp $
* *
* Authors: Gildas Bazin <gbazin@netcourrier.com> * Authors: Gildas Bazin <gbazin@netcourrier.com>
* *
...@@ -430,6 +430,7 @@ static int Activate( vlc_object_t * p_this ) ...@@ -430,6 +430,7 @@ static int Activate( vlc_object_t * p_this )
goto error; goto error;
} }
p_input->stream.p_selected_program = p_input->stream.pp_programs[0]; p_input->stream.p_selected_program = p_input->stream.pp_programs[0];
p_input->stream.i_mux_rate = 0;
vlc_mutex_unlock( &p_input->stream.stream_lock ); vlc_mutex_unlock( &p_input->stream.stream_lock );
for( i_stream = 0 ; i_stream < p_ogg->i_streams; i_stream++ ) for( i_stream = 0 ; i_stream < p_ogg->i_streams; i_stream++ )
...@@ -439,6 +440,7 @@ static int Activate( vlc_object_t * p_this ) ...@@ -439,6 +440,7 @@ static int Activate( vlc_object_t * p_this )
p_stream->p_es = input_AddES( p_input, p_stream->p_es = input_AddES( p_input,
p_input->stream.p_selected_program, p_input->stream.p_selected_program,
p_ogg->i_streams + 1, 0 ); p_ogg->i_streams + 1, 0 );
p_input->stream.i_mux_rate += (p_stream->i_bitrate / ( 8 * 50 ));
vlc_mutex_unlock( &p_input->stream.stream_lock ); vlc_mutex_unlock( &p_input->stream.stream_lock );
p_stream->p_es->i_stream_id = i_stream; p_stream->p_es->i_stream_id = i_stream;
p_stream->p_es->i_fourcc = p_stream->i_fourcc; p_stream->p_es->i_fourcc = p_stream->i_fourcc;
...@@ -446,10 +448,6 @@ static int Activate( vlc_object_t * p_this ) ...@@ -446,10 +448,6 @@ static int Activate( vlc_object_t * p_this )
#undef p_stream #undef p_stream
} }
vlc_mutex_lock( &p_input->stream.stream_lock );
p_input->stream.i_mux_rate = 0;
vlc_mutex_unlock( &p_input->stream.stream_lock );
for( i_stream = 0; i_stream < p_ogg->i_streams; i_stream++ ) for( i_stream = 0; i_stream < p_ogg->i_streams; i_stream++ )
{ {
#define p_stream p_ogg->pp_stream[i_stream] #define p_stream p_ogg->pp_stream[i_stream]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment