diff options
Diffstat (limited to 'scene/audio/audio_stream_player.h')
-rw-r--r-- | scene/audio/audio_stream_player.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/scene/audio/audio_stream_player.h b/scene/audio/audio_stream_player.h index ab98d41302..d8f83ee38d 100644 --- a/scene/audio/audio_stream_player.h +++ b/scene/audio/audio_stream_player.h @@ -31,6 +31,7 @@ #ifndef AUDIO_STREAM_PLAYER_H #define AUDIO_STREAM_PLAYER_H +#include "core/templates/safe_refcount.h" #include "scene/main/node.h" #include "servers/audio/audio_stream.h" @@ -49,12 +50,12 @@ private: Ref<AudioStream> stream; Vector<AudioFrame> mix_buffer; Vector<AudioFrame> fadeout_buffer; - bool use_fadeout = false; + bool use_fadeout; - volatile float setseek = -1.0; - volatile bool active = false; - volatile bool setstop = false; - volatile bool stop_has_priority = false; + SafeNumeric<float> setseek{ -1.0 }; + SafeFlag active; + SafeFlag setstop; + SafeFlag stop_has_priority; float mix_volume_db = 0.0; float pitch_scale = 1.0; |