Linux OpenAL fixes (music plays now as stereo)
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@308 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
0.2:
|
||||
- Linux OpenAL fixes (music plays now as stereo)
|
||||
- Fuel giveaway bug fixed, from steve@blckknght.org
|
||||
- Starmap fuel range calculator and actual consumption matches now
|
||||
- Collision detection is now pixel-perfect (fixes Sa-Matra, BUTT missile, etc)
|
||||
|
||||
@@ -37,8 +37,6 @@ Glitches (don't crash the game, medium priority):
|
||||
though.
|
||||
- OpenAL sound code problems:
|
||||
- Some unimplemented functions (for oscilloscope and dialogue seeking)
|
||||
- Linux OpenAL implementation sucks, so for now we are using SDL_mixer
|
||||
on that platform.
|
||||
- Volume levels aren't maybe exactly as they should
|
||||
- Crashes if no audio device available
|
||||
- Color table transformations are very slow.
|
||||
|
||||
@@ -156,7 +156,7 @@ _GetMusicData (FILE *fp, DWORD length)
|
||||
}
|
||||
|
||||
fprintf (stderr, "_GetMusicData(): loading %s\n", filename);
|
||||
if (((*pmus)->decoder = SoundDecoder_Load (filename, 16384)) == 0)
|
||||
if (((*pmus)->decoder = SoundDecoder_Load (filename, 4096)) == 0)
|
||||
{
|
||||
fprintf (stderr, "_GetMusicData(): couldn't load %s\n", filename);
|
||||
|
||||
@@ -169,7 +169,7 @@ _GetMusicData (FILE *fp, DWORD length)
|
||||
fprintf (stderr, " decoder: %s, rate %d format %x\n", (*pmus)->decoder->decoder_info,
|
||||
(*pmus)->decoder->frequency, (*pmus)->decoder->format);
|
||||
|
||||
(*pmus)->num_buffers = 16;
|
||||
(*pmus)->num_buffers = 64;
|
||||
(*pmus)->buffer = (ALuint *) HMalloc (sizeof (ALuint) * (*pmus)->num_buffers);
|
||||
alGenBuffers ((*pmus)->num_buffers, (*pmus)->buffer);
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
#include "sound.h"
|
||||
|
||||
#if 0 && !defined (WIN32) // && !defined (MacOS and BEOS too)
|
||||
#if !defined (WIN32) // && !defined (MacOS and BeOS too)
|
||||
#include <AL/alext.h>
|
||||
#endif
|
||||
|
||||
@@ -53,7 +53,7 @@ PlayStream (TFB_SoundSample *sample, ALuint source, ALboolean looping)
|
||||
if (decoded_bytes == 0)
|
||||
break;
|
||||
|
||||
#if 0 && !defined (WIN32) // && !defined (MacOS and BeOS too)
|
||||
#if !defined (WIN32) // && !defined (MacOS and BeOS too)
|
||||
// *nix OpenAL implementation has to handle stereo data differently to avoid mixing it to mono
|
||||
|
||||
if (sample->decoder->format == AL_FORMAT_STEREO8 ||
|
||||
@@ -219,7 +219,7 @@ StreamDecoderTaskFunc (void *data)
|
||||
|
||||
if (decoded_bytes > 0)
|
||||
{
|
||||
#if 0 && !defined (WIN32) // && !defined (MacOS and BeOS too)
|
||||
#if !defined (WIN32) // && !defined (MacOS and BeOS too)
|
||||
// *nix OpenAL implementation has to handle stereo data differently to avoid mixing it to mono
|
||||
|
||||
if (soundSource[i].sample->decoder->format == AL_FORMAT_STEREO8 ||
|
||||
|
||||
Reference in New Issue
Block a user