Lines 967-973
Link Here
|
967 |
#ifdef LOG_TRICKSPEED |
967 |
#ifdef LOG_TRICKSPEED |
968 |
if(PictureType != NO_PICTURE && PES_HAS_PTS(buf)) { |
968 |
if(PictureType != NO_PICTURE && PES_HAS_PTS(buf)) { |
969 |
int64_t pts = pes_get_pts(buf, length); |
969 |
int64_t pts = pes_get_pts(buf, length); |
970 |
LOGMSG(" TrickSpeed: frame %s pts %"PRId64, picture_type_str[PictureType], pts); |
970 |
LOGMSG(" TrickSpeed: frame %s pts %" PRId64, picture_type_str[PictureType], pts); |
971 |
} |
971 |
} |
972 |
#endif |
972 |
#endif |
973 |
|
973 |
|
Lines 1019-1029
Link Here
|
1019 |
if(m_TrickSpeedPts == 0) { |
1019 |
if(m_TrickSpeedPts == 0) { |
1020 |
m_TrickSpeedMode |= trs_NoAudio; |
1020 |
m_TrickSpeedMode |= trs_NoAudio; |
1021 |
m_TrickSpeedPts = pts; |
1021 |
m_TrickSpeedPts = pts; |
1022 |
LOGTRICKSPEED(" Seen video pts = %"PRId64, pts); |
1022 |
LOGTRICKSPEED(" Seen video pts = %" PRId64, pts); |
1023 |
} else { |
1023 |
} else { |
1024 |
if(pts < m_TrickSpeedPts) { |
1024 |
if(pts < m_TrickSpeedPts) { |
1025 |
/* -> playing fast backwards */ |
1025 |
/* -> playing fast backwards */ |
1026 |
LOGTRICKSPEED(" Detected fast backward mode. last %"PRId64" now %"PRId64, |
1026 |
LOGTRICKSPEED(" Detected fast backward mode. last %" PRId64 " now %" PRId64, |
1027 |
m_TrickSpeedPts, pts); |
1027 |
m_TrickSpeedPts, pts); |
1028 |
//if(!(m_TrickSpeedMode & trs_PTS_recalc)) |
1028 |
//if(!(m_TrickSpeedMode & trs_PTS_recalc)) |
1029 |
// ForEach(m_clients, &cXinelibThread::Clear); |
1029 |
// ForEach(m_clients, &cXinelibThread::Clear); |
Lines 1051-1057
Link Here
|
1051 |
if(m_TrickSpeedPts == 0) |
1051 |
if(m_TrickSpeedPts == 0) |
1052 |
m_TrickSpeedPts = pts; |
1052 |
m_TrickSpeedPts = pts; |
1053 |
|
1053 |
|
1054 |
LOGTRICKSPEED(" pts %"PRId64" -> %"PRId64" (diff %"PRId64") %"PRId64"", pts, |
1054 |
LOGTRICKSPEED(" pts %" PRId64 " -> %" PRId64 " (diff %" PRId64 ") %" PRId64 "", pts, |
1055 |
m_TrickSpeedPts + 40*12*90, m_TrickSpeedPts + 40*12*90 - pts, |
1055 |
m_TrickSpeedPts + 40*12*90, m_TrickSpeedPts + 40*12*90 - pts, |
1056 |
(m_TrickSpeedPts + 40*12*90)^0x80000000); |
1056 |
(m_TrickSpeedPts + 40*12*90)^0x80000000); |
1057 |
pts = m_TrickSpeedPts = m_TrickSpeedPts + 40*12*90; /* 12 frames * 40ms -> pts units */ |
1057 |
pts = m_TrickSpeedPts = m_TrickSpeedPts + 40*12*90; /* 12 frames * 40ms -> pts units */ |