Commit d6d7bb61 authored by Jean-Paul Saman's avatar Jean-Paul Saman

Treat all live555 versions before LIVEMEDIA_LIBRARY_VERSION_INT 1171929600 as...

Treat all live555 versions before LIVEMEDIA_LIBRARY_VERSION_INT 1171929600 as if playStartTime() and playEndTime() didn't exist. Now only handle unpatched current versions of live library. 
parent c9569b35
......@@ -848,13 +848,21 @@ static int SessionsSetup( demux_t *p_demux )
delete iter;
if( p_sys->i_track <= 0 ) i_return = VLC_EGENERIC;
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the starttime if possible */
p_sys->i_npt_start = (int64_t)( p_sys->ms->playStartTime() * (double)1000000.0 );
#else
p_sys->i_npt_start = (int64_t) = -1;
#endif
if( p_sys->i_npt_start < 0 )
p_sys->i_npt_start = -1;
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the duration if possible */
p_sys->i_npt_length = (int64_t)( p_sys->ms->playEndTime() * (double)1000000.0 );
#else
p_sys->i_npt_length = (int64_t) -1;
#endif
if( p_sys->i_npt_length < 0 )
p_sys->i_npt_length = -1;
......@@ -908,8 +916,12 @@ static int Play( demux_t *p_demux )
}
#endif
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the starttime if possible */
p_sys->i_npt_start = (int64_t)( p_sys->ms->playStartTime() * (double)1000000.0 );
#else
p_sys->i_npt_start = (int64_t) -1;
#endif
if( p_sys->i_npt_start < 0 )
{
p_sys->i_npt_start = -1;
......@@ -918,8 +930,12 @@ static int Play( demux_t *p_demux )
else
p_sys->i_npt = p_sys->i_npt_start;
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the duration if possible */
p_sys->i_npt_length = (int64_t)( p_sys->ms->playEndTime() * (double)1000000.0 );
#else
p_sys->i_npt_length = -1;
#endif
if( p_sys->i_npt_length < 0 )
p_sys->i_npt_length = -1;
......@@ -1115,8 +1131,12 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
msg_Dbg( p_demux, "set pos startseq: %u", p_sys->track[i]->i_start_seq );
}
#endif
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the starttime if possible */
p_sys->i_npt_start = (int64_t)( p_sys->ms->playStartTime() * (double)1000000.0 );
#else
p_sys->i_npt_start = (int64_t) -1;
#endif
if( p_sys->i_npt_start < 0 )
{
p_sys->i_npt_start = -1;
......@@ -1125,8 +1145,12 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
else
p_sys->i_npt = p_sys->i_npt_start;
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the duration if possible */
p_sys->i_npt_length = (int64_t)( p_sys->ms->playEndTime() * (double)1000000.0 );
#else
p_sys->i_npt_lenght = (int64_t) -1;
#endif
if( p_sys->i_npt_length < 0 )
p_sys->i_npt_length = -1;
......@@ -1183,9 +1207,12 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
msg_Dbg( p_demux, "set pause startseq: %u", p_sys->track[i]->i_start_seq );
}
#endif
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the starttime if possible */
p_sys->i_npt_start = (int64_t)( p_sys->ms->playStartTime() * (double)1000000.0 );
#else
p_sys->i_npt_start = (int64_t) -1;
#endif
if( p_sys->i_npt_start < 0 )
{
p_sys->i_npt_start = -1;
......@@ -1194,8 +1221,12 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
else
p_sys->i_npt = p_sys->i_npt_start;
#if (LIVEMEDIA_LIBRARY_VERSION_INT >= 1171929600)
/* Retrieve the duration if possible */
p_sys->i_npt_length = (int64_t)( p_sys->ms->playEndTime() * (double)1000000.0 );
#else
p_sys->i_npt_lenght = (int64_t) -1;
#endif
if( p_sys->i_npt_length < 0 )
p_sys->i_npt_length = -1;
......
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