[vlc-devel] commit: Removed all clock dependencies on input. (Laurent Aimar )
git version control
git at videolan.org
Sun Sep 28 13:35:58 CEST 2008
vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Wed Sep 24 22:27:31 2008 +0200| [77dbb1a450ecb2c521847966c5ff7069ae8e7805] | committer: Laurent Aimar
Removed all clock dependencies on input.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=77dbb1a450ecb2c521847966c5ff7069ae8e7805
---
src/input/clock.c | 10 +++++-----
src/input/es_out.c | 6 ++++--
src/input/input_internal.h | 3 ++-
3 files changed, 11 insertions(+), 8 deletions(-)
diff --git a/src/input/clock.c b/src/input/clock.c
index 4bd82b4..29fc354 100644
--- a/src/input/clock.c
+++ b/src/input/clock.c
@@ -192,10 +192,10 @@ void input_clock_Delete( input_clock_t *cl )
* i_ck_system: date in system clock
*****************************************************************************/
void input_clock_SetPCR( input_clock_t *cl,
- input_thread_t *p_input,
+ vlc_object_t *p_log, bool b_can_pace_control,
mtime_t i_ck_stream, mtime_t i_ck_system )
{
- const bool b_synchronize = p_input->b_can_pace_control && cl->b_master;
+ const bool b_synchronize = b_can_pace_control && cl->b_master;
bool b_reset_reference = false;
if( ( !cl->b_has_reference ) ||
@@ -213,11 +213,11 @@ void input_clock_SetPCR( input_clock_t *cl,
/* Stream discontinuity, for which we haven't received a
* warning from the stream control facilities (dd-edited
* stream ?). */
- msg_Warn( p_input, "clock gap, unexpected stream discontinuity" );
+ msg_Warn( p_log, "clock gap, unexpected stream discontinuity" );
cl->last_pts = 0;
/* */
- msg_Warn( p_input, "feeding synchro with a new reference point trying to recover from clock gap" );
+ msg_Warn( p_log, "feeding synchro with a new reference point trying to recover from clock gap" );
b_reset_reference= true;
}
if( b_reset_reference )
@@ -294,7 +294,7 @@ void input_clock_SetMaster( input_clock_t *cl, bool b_master )
/*****************************************************************************
* input_clock_GetWakeup
*****************************************************************************/
-mtime_t input_clock_GetWakeup( input_clock_t *cl, input_thread_t *p_input )
+mtime_t input_clock_GetWakeup( input_clock_t *cl )
{
/* Not synchronized, we cannot wait */
if( !cl->b_has_reference )
diff --git a/src/input/es_out.c b/src/input/es_out.c
index b62d05c..99ddec1 100644
--- a/src/input/es_out.c
+++ b/src/input/es_out.c
@@ -351,7 +351,8 @@ es_out_id_t *input_EsOutGetFromID( es_out_t *out, int i_id )
mtime_t input_EsOutGetWakeup( es_out_t *out )
{
- es_out_sys_t *p_sys = out->p_sys;
+ es_out_sys_t *p_sys = out->p_sys;
+ input_thread_t *p_input = p_sys->p_input;
if( !p_sys->p_pgrm )
return 0;
@@ -1916,7 +1917,8 @@ static int EsOutControl( es_out_t *out, int i_query, va_list args )
i_pcr = (int64_t)va_arg( args, int64_t );
/* search program
* TODO do not use mdate() but proper stream acquisition date */
- input_clock_SetPCR( p_pgrm->p_clock, p_sys->p_input, i_pcr, mdate() );
+ input_clock_SetPCR( p_pgrm->p_clock, VLC_OBJECT(p_sys->p_input),
+ p_sys->p_input->b_can_pace_control, i_pcr, mdate() );
return VLC_SUCCESS;
}
diff --git a/src/input/input_internal.h b/src/input/input_internal.h
index df087ec..805702d 100644
--- a/src/input/input_internal.h
+++ b/src/input/input_internal.h
@@ -361,7 +361,8 @@ typedef struct input_clock_t input_clock_t;
input_clock_t *input_clock_New( bool b_master, int i_cr_average, int i_rate );
void input_clock_Delete( input_clock_t * );
-void input_clock_SetPCR( input_clock_t *, input_thread_t *, mtime_t i_clock, mtime_t i_system );
+void input_clock_SetPCR( input_clock_t *, vlc_object_t *p_log,
+ bool b_can_pace_control, mtime_t i_clock, mtime_t i_system );
void input_clock_ResetPCR( input_clock_t * );
mtime_t input_clock_GetTS( input_clock_t *, mtime_t i_pts_delay, mtime_t );
void input_clock_SetRate( input_clock_t *cl, int i_rate );
More information about the vlc-devel
mailing list