1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2025-07-03 22:44:32 +00:00

sync with icculus repo

This commit is contained in:
fgenesis 2012-02-09 17:40:35 +01:00
parent 5623b11f83
commit 321a65a9fb
2 changed files with 15 additions and 22 deletions

View file

@ -360,7 +360,7 @@ void OggDecoder::decode_loop(OggDecoder *this_)
while (!this_->stop_thread)
{
#ifdef BBGE_BUILD_SDL
SDL_Delay(1);
SDL_Delay(10);
#endif
int processed = 0;
@ -376,6 +376,12 @@ void OggDecoder::decode_loop(OggDecoder *this_)
}
}
#if (defined(BBGE_BUILD_SDL) && (SDL_BYTEORDER == SDL_BIG_ENDIAN))
#define BBGE_BIGENDIAN 1
#else
#define BBGE_BIGENDIAN 0
#endif
void OggDecoder::queue(ALuint buffer)
{
if (!playing || eof)
@ -391,7 +397,8 @@ void OggDecoder::queue(ALuint buffer)
int bitstream_unused;
const int nread = ov_read(
&vf, pcm_buffer + pcm_size, buffer_size - pcm_size,
/*bigendianp*/ 0, /*word*/ 2, /*sgned*/ 1, &bitstream_unused
/*bigendianp*/ BBGE_BIGENDIAN, /*word*/ 2, /*sgned*/ 1,
&bitstream_unused
);
if (nread == 0 || nread == OV_EOF)
{
@ -513,8 +520,6 @@ namespace FMOD {
return ((OpenAL##cls *) this)->method args; \
}
static ALenum GVorbisFormat = AL_NONE;
// FMOD::Sound implementation ...
class OpenALSound
@ -1217,17 +1222,6 @@ FMOD_RESULT OpenALSystem::init(int maxchannels, const FMOD_INITFLAGS flags, cons
SANITY_CHECK_OPENAL_CALL();
GVorbisFormat = AL_NONE;
if (alIsExtensionPresent("AL_EXT_vorbis"))
GVorbisFormat = alGetEnumValue("AL_FORMAT_VORBIS_EXT");
#if 0 // Disabled output: every bug report thinks this is the culprit. --ryan.
if (GVorbisFormat == AL_NONE)
fprintf(stderr, "WARNING: no AL_EXT_vorbis support. We'll use more RAM.\n");
#endif
SANITY_CHECK_OPENAL_CALL();
master_channel_group = new OpenALChannelGroup("master");
num_channels = maxchannels;