From 2b5b2a0e0123bf74325f7ee34cbf779c6c411996 Mon Sep 17 00:00:00 2001 From: bgk Date: Wed, 14 Jan 2009 12:02:19 +0000 Subject: [PATCH] Add an initializer for a static const member. git-svn-id: https://svn.code.sf.net/p/vbam/code/trunk@850 a31d4220-a93d-0410-bf67-fe4944624d44 --- src/common/SoundSDL.cpp | 3 +++ src/common/SoundSDL.h | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/common/SoundSDL.cpp b/src/common/SoundSDL.cpp index c1785b8c..8733ca5c 100644 --- a/src/common/SoundSDL.cpp +++ b/src/common/SoundSDL.cpp @@ -20,6 +20,9 @@ extern int emulating; extern bool speedup; +// Hold up to 100 ms of data in the ring buffer +const float SoundSDL::_delay = 0.1f; + SoundSDL::SoundSDL(): _rbuf(0) { diff --git a/src/common/SoundSDL.h b/src/common/SoundSDL.h index 70cf1f0e..34c2b729 100644 --- a/src/common/SoundSDL.h +++ b/src/common/SoundSDL.h @@ -41,8 +41,8 @@ private: SDL_cond * _cond; SDL_mutex * _mutex; - // Hold up to 100 ms of data in the ring buffer - static const float _delay = 0.1f; + // Defines what delay in seconds we keep in the sound buffer + static const float _delay; static void soundCallback(void *data, u8 *stream, int length); virtual void read(u16 * stream, int length);