From: Alexander Monakov Date: Fri, 17 Dec 2010 23:46:27 +0000 (+0300) Subject: Make static X-Git-Url: https://git.jsancho.org/?a=commitdiff_plain;h=f115b28d45767b70ee0586e6ac6b55484b9ed692;p=lugaru.git Make static --- diff --git a/Source/openal_wrapper.cpp b/Source/openal_wrapper.cpp index bd46990..a87b80c 100644 --- a/Source/openal_wrapper.cpp +++ b/Source/openal_wrapper.cpp @@ -265,14 +265,14 @@ AL_API void OPENAL_Close() initialized = false; } -AL_API OPENAL_SAMPLE *OPENAL_GetCurrentSample(int channel) +static OPENAL_SAMPLE *OPENAL_GetCurrentSample(int channel) { if (!initialized) return NULL; if ((channel < 0) || (channel >= num_channels)) return NULL; return impl_channels[channel].sample; } -AL_API signed char OPENAL_GetPaused(int channel) +static signed char OPENAL_GetPaused(int channel) { if (!initialized) return false; if ((channel < 0) || (channel >= num_channels)) return false; @@ -284,7 +284,7 @@ AL_API signed char OPENAL_GetPaused(int channel) return((state == AL_PAUSED) ? true : false); } -AL_API unsigned int OPENAL_GetLoopMode(int channel) +static unsigned int OPENAL_GetLoopMode(int channel) { if (!initialized) return 0; if ((channel < 0) || (channel >= num_channels)) return 0; @@ -304,7 +304,7 @@ AL_API signed char OPENAL_IsPlaying(int channel) return((state == AL_PLAYING) ? true : false); } -AL_API int OPENAL_PlaySoundEx(int channel, OPENAL_SAMPLE *sptr, OPENAL_DSPUNIT *dsp, signed char startpaused) +static int OPENAL_PlaySoundEx(int channel, OPENAL_SAMPLE *sptr, OPENAL_DSPUNIT *dsp, signed char startpaused) { if (!initialized) return -1; if (sptr == NULL) return -1; @@ -487,7 +487,7 @@ AL_API void OPENAL_Sample_Free(OPENAL_SAMPLE *sptr) } } -AL_API signed char OPENAL_Sample_SetMode(OPENAL_SAMPLE *sptr, unsigned int mode) +static signed char OPENAL_Sample_SetMode(OPENAL_SAMPLE *sptr, unsigned int mode) { if (!initialized) return false; if ((mode != OPENAL_LOOP_NORMAL) && (mode != OPENAL_LOOP_OFF)) return false; @@ -592,18 +592,18 @@ AL_API void OPENAL_Stream_Close(OPENAL_STREAM *stream) OPENAL_Sample_Free((OPENAL_SAMPLE *) stream); } -AL_API OPENAL_SAMPLE *OPENAL_Stream_GetSample(OPENAL_STREAM *stream) +static OPENAL_SAMPLE *OPENAL_Stream_GetSample(OPENAL_STREAM *stream) { if (!initialized) return NULL; return (OPENAL_SAMPLE *) stream; } -AL_API int OPENAL_Stream_PlayEx(int channel, OPENAL_STREAM *stream, OPENAL_DSPUNIT *dsp, signed char startpaused) +static int OPENAL_Stream_PlayEx(int channel, OPENAL_STREAM *stream, OPENAL_DSPUNIT *dsp, signed char startpaused) { return OPENAL_PlaySoundEx(channel, (OPENAL_SAMPLE *) stream, dsp, startpaused); } -AL_API signed char OPENAL_Stream_Stop(OPENAL_STREAM *stream) +static signed char OPENAL_Stream_Stop(OPENAL_STREAM *stream) { if (!initialized) return false; for (int i = 0; i < num_channels; i++) diff --git a/Source/openal_wrapper.h b/Source/openal_wrapper.h index f0b730f..815bff0 100644 --- a/Source/openal_wrapper.h +++ b/Source/openal_wrapper.h @@ -72,23 +72,15 @@ AL_API void OPENAL_3D_Listener_SetAttributes(const float *pos, const float *vel, AL_API signed char OPENAL_3D_SetAttributes(int channel, const float *pos, const float *vel); AL_API signed char OPENAL_Init(int mixrate, int maxsoftwarechannels, unsigned int flags); AL_API void OPENAL_Close(); -AL_API OPENAL_SAMPLE *OPENAL_GetCurrentSample(int channel); -AL_API signed char OPENAL_GetPaused(int channel); -AL_API unsigned int OPENAL_GetLoopMode(int channel); AL_API signed char OPENAL_IsPlaying(int channel); -AL_API int OPENAL_PlaySoundEx(int channel, OPENAL_SAMPLE *sptr, OPENAL_DSPUNIT *dsp, signed char startpaused); AL_API OPENAL_SAMPLE *OPENAL_Sample_Load(int index, const char *name_or_data, unsigned int mode, int offset, int length); AL_API void OPENAL_Sample_Free(OPENAL_SAMPLE *sptr); -AL_API signed char OPENAL_Sample_SetMode(OPENAL_SAMPLE *sptr, unsigned int mode); AL_API signed char OPENAL_SetFrequency(int channel, int freq); AL_API signed char OPENAL_SetVolume(int channel, int vol); AL_API signed char OPENAL_SetPaused(int channel, signed char paused); AL_API void OPENAL_SetSFXMasterVolume(int volume); AL_API signed char OPENAL_StopSound(int channel); AL_API void OPENAL_Stream_Close(OPENAL_STREAM *stream); -AL_API OPENAL_SAMPLE *OPENAL_Stream_GetSample(OPENAL_STREAM *stream); -AL_API int OPENAL_Stream_PlayEx(int channel, OPENAL_STREAM *stream, OPENAL_DSPUNIT *dsp, signed char startpaused); -AL_API signed char OPENAL_Stream_Stop(OPENAL_STREAM *stream); AL_API signed char OPENAL_Stream_SetMode(OPENAL_STREAM *stream, unsigned int mode); AL_API void OPENAL_Update(); AL_API signed char OPENAL_SetOutput(int outputtype);