2023-12-15 Fred Gleason <fredg@paravelsystems.com>

* Fixed a race in the log machine logic that could cause truncated
	play-outs with segue transitions.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason 2023-12-15 16:49:46 -05:00
parent 9756d444bf
commit af8b711649
4 changed files with 9 additions and 2 deletions

View File

@ -24559,3 +24559,6 @@
CAE command. CAE command.
2023-12-15 Fred Gleason <fredg@paravelsystems.com> 2023-12-15 Fred Gleason <fredg@paravelsystems.com>
* Cleaned up warnings about unprocessed CAE commands in the syslog. * Cleaned up warnings about unprocessed CAE commands in the syslog.
2023-12-15 Fred Gleason <fredg@paravelsystems.com>
* Fixed a race in the log machine logic that could cause truncated
play-outs with segue transitions.

View File

@ -287,6 +287,7 @@ void RDCae::play(unsigned serial,unsigned length,int speed,bool pitch)
if(pitch) { if(pitch) {
pitch_state=1; pitch_state=1;
} }
//printf(" play: %s\n",QTime::currentTime().toString("hh:mm:ss.zzz").toUtf8().constData());
SendCommand(QString().sprintf("PY %u %u %d %d!", SendCommand(QString().sprintf("PY %u %u %d %d!",
serial,length,speed,pitch_state)); serial,length,speed,pitch_state));
} }

View File

@ -1520,7 +1520,7 @@ void RDLogPlay::graceTimerData()
void RDLogPlay::playStateChangedData(int id,RDPlayDeck::State state) void RDLogPlay::playStateChangedData(int id,RDPlayDeck::State state)
{ {
#ifdef SHOW_SLOTS #ifdef SHOW_SLOTS
printf("playStateChangedData(%d,%d), log: %s\n",id,state,(const char *)logName()); printf("playStateChangedData(%d,%d), log: %s\n",id,state,logName().toUtf8().constData());
#endif #endif
switch(state) { switch(state) {
case RDPlayDeck::Playing: case RDPlayDeck::Playing:

View File

@ -666,12 +666,14 @@ void RDPlayDeck::pointTimerData(int point)
case RDPlayDeck::Segue: case RDPlayDeck::Segue:
if(play_point_state[point]) { if(play_point_state[point]) {
play_point_state[point]=false; play_point_state[point]=false;
//printf(" segueEnd: %s\n",QTime::currentTime().toString("hh:mm:ss.zzz").toUtf8().constData());
emit segueEnd(play_id); emit segueEnd(play_id);
} }
else { else {
play_point_state[point]=true; play_point_state[point]=true;
play_point_timer[point]-> play_point_timer[point]->
start(play_point_value[point][1]-play_point_value[point][0]); start(play_point_value[point][1]-play_point_value[point][0]);
//printf("segueStart: %s\n",QTime::currentTime().toString("hh:mm:ss.zzz").toUtf8().constData());
emit segueStart(play_id); emit segueStart(play_id);
} }
break; break;
@ -767,7 +769,8 @@ void RDPlayDeck::StartTimers(int offset)
for(int i=0;i<RDPlayDeck::SizeOf;i++) { for(int i=0;i<RDPlayDeck::SizeOf;i++) {
play_point_state[i]=false; play_point_state[i]=false;
if(play_point_value[i][0]!=-1) { if((play_point_value[i][0]!=-1)&&
(play_point_value[i][0]!=play_point_value[i][1])) {
audio_point=(int) audio_point=(int)
(RD_TIMESCALE_DIVISOR*(double)play_audio_point[0]/ (RD_TIMESCALE_DIVISOR*(double)play_audio_point[0]/
(double)play_timescale_speed); (double)play_timescale_speed);