diff options
author | 2014-02-24 03:25:05 +0000 | |
---|---|---|
committer | 2014-02-24 03:25:05 +0000 | |
commit | 172056e7598d3447c682a694d824041076f3255e (patch) | |
tree | 3ba150866d6bbcc337932e3fc59a3af9715d0d85 /hge/sound.cpp | |
parent | 8cb1a0f4fcf8e7ecd54134e8d6f431b613c69091 (diff) | |
download | bullet-lab-remix-172056e7598d3447c682a694d824041076f3255e.tar.xz |
M trunk/CHANGELOG.TXT
M trunk/background.h
M trunk/effects.h
M trunk/global.h
M trunk/hge/CxImage/ximagif.cpp
M trunk/hge/CxImage/ximaint.cpp
M trunk/hge/CxImage/ximapng.cpp
M trunk/hge/graphics.cpp
M trunk/hge/input.cpp
M trunk/hge/resource.cpp
M trunk/hge/sound.cpp
M trunk/hge/system.cpp
M trunk/hgehelp/hgefont.cpp
M trunk/levels.h
M trunk/libcgh.h
M trunk/libcghEx.cpp
M trunk/menuitem.cpp
M trunk/menuitem.h
M trunk/menus.h
M trunk/music.h
M trunk/scorec.h
M trunk/scoresystem.h
M trunk/towernbullet.h
Diffstat (limited to 'hge/sound.cpp')
-rw-r--r-- | hge/sound.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/hge/sound.cpp b/hge/sound.cpp index bd9a8d7..5880b5a 100644 --- a/hge/sound.cpp +++ b/hge/sound.cpp @@ -23,7 +23,7 @@ #include "AL/alext.h" #include "ogg/ogg.h" #include "vorbis/vorbisfile.h" -static const char* SOUND_SRC_FN="hge/sound_openal.cpp"; +static const char* SOUND_SRC_FN="hge/sound.cpp"; struct oggcbdata { const BYTE *data; @@ -113,7 +113,7 @@ static void *decompress_vorbis(const BYTE *data, const DWORD size, ALsizei *deco if (rc > 0) { *decompressed_size += rc; - if (*decompressed_size >= allocated) + if ((unsigned)*decompressed_size >= allocated) { allocated *= 2; ALubyte *tmp = (ALubyte *) realloc(retval, allocated); @@ -162,7 +162,7 @@ static ALuint get_source() HEFFECT CALL HGE_Impl::Effect_Load(const char *filename, DWORD size) { - DWORD _size, length, samples; + DWORD _size; void *data; if(hOpenAL) @@ -192,17 +192,17 @@ HEFFECT CALL HGE_Impl::Effect_Load(const char *filename, DWORD size) ALenum fmt = AL_FORMAT_STEREO16; if (isOgg) { - if (alIsExtensionPresent((const ALchar *) "AL_EXT_vorbis")) + /*if (alIsExtensionPresent((const ALchar *) "AL_EXT_vorbis"))//useless { fmt = alGetEnumValue((const ALchar *) "AL_FORMAT_VORBIS_EXT"); decompressed = data; decompressed_size = _size; } else - { + {*/ allocation_decompressed = decompress_vorbis((const BYTE *) data, _size, &decompressed_size, &fmt, &freq); decompressed = allocation_decompressed; - } + //} } ALuint bid = 0; |