From 0111a2c71ce1ed33e72a5aee15c5e33b014344ca Mon Sep 17 00:00:00 2001 From: curt Date: Tue, 4 Feb 2003 18:18:24 +0000 Subject: [PATCH] Fix a bug in transit sound termination and adjust the minimum time we wait with no change before stoping the sound. --- src/Sound/fg_sound.cxx | 2 +- src/Sound/fg_sound.hxx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Sound/fg_sound.cxx b/src/Sound/fg_sound.cxx index b11ba1590..9f20d3b6d 100644 --- a/src/Sound/fg_sound.cxx +++ b/src/Sound/fg_sound.cxx @@ -270,7 +270,7 @@ FGSound::update (double dt) ) { - if ((_mode != FGSound::IN_TRANSIT) || (_stopping < MAX_TRANSIT_TIME)) { + if ((_mode != FGSound::IN_TRANSIT) || (_stopping > MAX_TRANSIT_TIME)) { if (_sample->is_playing()) { SG_LOG(SG_GENERAL, SG_INFO, "Stopping audio after " << _dt_play diff --git a/src/Sound/fg_sound.hxx b/src/Sound/fg_sound.hxx index e3c0cda46..ce66e13a3 100644 --- a/src/Sound/fg_sound.hxx +++ b/src/Sound/fg_sound.hxx @@ -33,7 +33,7 @@ #include "soundmgr.hxx" -static const double MAX_TRANSIT_TIME = 0.01; // 10 ms. +static const double MAX_TRANSIT_TIME = 0.1; // 10 ms. /**