Skip to content

Commit

Permalink
update catch up time frame
Browse files Browse the repository at this point in the history
Signed-off-by: Ian Chen <ichen@osrfoundation.org>
  • Loading branch information
iche033 committed Oct 24, 2020
1 parent d3f8f38 commit 08f1c38
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions subt_ign/src/PlaybackEventRecorder.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1036,20 +1036,20 @@ void PlaybackEventRecorder::PostUpdate(
recorderStats.sec();
if (!this->dataPtr->catchupOnRecording)
{
if (recorderStats.sec() != 0 && lag > 45)
if (recorderStats.sec() != 0 && lag > 10)
{
this->dataPtr->eventManager->Emit<events::Pause>(true);
this->dataPtr->catchupOnRecording = true;
ignmsg << "Pausing to catch up on recording " << std::endl;
ignmsg << "Recording Video: " << recorderStats.sec()
<< "s (sim time)" << std::endl;
}
}
else
{
if (lag < 15)
if (lag < 5)
{
this->dataPtr->eventManager->Emit<events::Pause>(false);
this->dataPtr->catchupOnRecording = false;
ignmsg << "Unpausing after catching up on recording " << std::endl;
}
}
}
Expand Down

0 comments on commit 08f1c38

Please sign in to comment.