Skip to content

Commit

Permalink
Merge branch 'master' of git://repo.or.cz/openal-soft
Browse files Browse the repository at this point in the history
  • Loading branch information
AerialX committed Mar 18, 2012
2 parents e09e682 + 703d72f commit 60e7d26
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 38 deletions.
9 changes: 4 additions & 5 deletions Alc/ALc.c
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,11 @@ static ALCchar *alcCaptureDefaultDeviceSpecifier;

static const ALCchar alcNoDeviceExtList[] =
"ALC_ENUMERATE_ALL_EXT ALC_ENUMERATION_EXT ALC_EXT_CAPTURE "
"ALC_EXT_thread_local_context ALC_SOFTX_loopback_device";
"ALC_EXT_thread_local_context ALC_SOFT_loopback";
static const ALCchar alcExtensionList[] =
"ALC_ENUMERATE_ALL_EXT ALC_ENUMERATION_EXT ALC_EXT_CAPTURE "
"ALC_EXT_DEDICATED ALC_EXT_disconnect ALC_EXT_EFX "
"ALC_EXT_thread_local_context ALC_SOFTX_loopback_device";
"ALC_EXT_thread_local_context ALC_SOFT_loopback";
static const ALCint alcMajorVersion = 1;
static const ALCint alcMinorVersion = 1;

Expand Down Expand Up @@ -2791,11 +2791,10 @@ ALC_API ALCboolean ALC_APIENTRY alcIsRenderFormatSupportedSOFT(ALCdevice *device
alcSetError(device, ALC_INVALID_DEVICE);
else if(freq <= 0)
alcSetError(device, ALC_INVALID_VALUE);
else if(!IsValidALCType(type) || !IsValidALCChannels(channels))
alcSetError(device, ALC_INVALID_ENUM);
else
{
if(BytesFromDevFmt(type) > 0 && ChannelsFromDevFmt(channels) > 0 &&
if(IsValidALCType(type) && BytesFromDevFmt(type) > 0 &&
IsValidALCChannels(channels) && ChannelsFromDevFmt(channels) > 0 &&
freq >= MIN_OUTPUT_RATE)
ret = ALC_TRUE;
}
Expand Down
2 changes: 1 addition & 1 deletion Alc/hrtf.c
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ void InitHrtf(void)

if(!failed)
{
for(i = 0;i < HRIR_COUNT;i++)
for(i = 0;i < ELEV_COUNT;i++)
{
ALushort offset;
offset = fgetc(f);
Expand Down
32 changes: 0 additions & 32 deletions OpenAL32/Include/alMain.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,38 +17,6 @@
#include "AL/alc.h"
#include "AL/alext.h"

#ifndef ALC_SOFT_device_loopback
#define ALC_SOFT_device_loopback 1
#define ALC_FORMAT_CHANNELS_SOFT 0x1990
#define ALC_FORMAT_TYPE_SOFT 0x1991

/* Sample types */
#define ALC_BYTE_SOFT 0x1400
#define ALC_UNSIGNED_BYTE_SOFT 0x1401
#define ALC_SHORT_SOFT 0x1402
#define ALC_UNSIGNED_SHORT_SOFT 0x1403
#define ALC_INT_SOFT 0x1404
#define ALC_UNSIGNED_INT_SOFT 0x1405
#define ALC_FLOAT_SOFT 0x1406

/* Channel configurations */
#define ALC_MONO_SOFT 0x1500
#define ALC_STEREO_SOFT 0x1501
#define ALC_QUAD_SOFT 0x1503
#define ALC_5POINT1_SOFT 0x1504 /* (WFX order) */
#define ALC_6POINT1_SOFT 0x1505 /* (WFX order) */
#define ALC_7POINT1_SOFT 0x1506 /* (WFX order) */

typedef ALCdevice* (ALC_APIENTRY*LPALCLOOPBACKOPENDEVICESOFT)(const ALCchar*);
typedef ALCboolean (ALC_APIENTRY*LPALCISRENDERFORMATSUPPORTEDSOFT)(ALCdevice*,ALCsizei,ALCenum,ALCenum);
typedef void (ALC_APIENTRY*LPALCRENDERSAMPLESSOFT)(ALCdevice*,ALCvoid*,ALCsizei);
#ifdef AL_ALEXT_PROTOTYPES
ALC_API ALCdevice* ALC_APIENTRY alcLoopbackOpenDeviceSOFT(const ALCchar *deviceName);
ALC_API ALCboolean ALC_APIENTRY alcIsRenderFormatSupportedSOFT(ALCdevice *device, ALCsizei freq, ALCenum channels, ALCenum type);
ALC_API void ALC_APIENTRY alcRenderSamplesSOFT(ALCdevice *device, ALCvoid *buffer, ALCsizei samples);
#endif
#endif

#ifndef AL_SOFT_deferred_updates
#define AL_SOFT_deferred_updates 1
#define AL_DEFERRED_UPDATES_SOFT 0xC002
Expand Down
32 changes: 32 additions & 0 deletions include/AL/alext.h
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,38 @@ AL_API ALboolean AL_APIENTRY alIsBufferFormatSupportedSOFT(ALenum format);
#define AL_DIRECT_CHANNELS_SOFT 0x1033
#endif

#ifndef ALC_SOFT_loopback
#define ALC_SOFT_loopback 1
#define ALC_FORMAT_CHANNELS_SOFT 0x1990
#define ALC_FORMAT_TYPE_SOFT 0x1991

/* Sample types */
#define ALC_BYTE_SOFT 0x1400
#define ALC_UNSIGNED_BYTE_SOFT 0x1401
#define ALC_SHORT_SOFT 0x1402
#define ALC_UNSIGNED_SHORT_SOFT 0x1403
#define ALC_INT_SOFT 0x1404
#define ALC_UNSIGNED_INT_SOFT 0x1405
#define ALC_FLOAT_SOFT 0x1406

/* Channel configurations */
#define ALC_MONO_SOFT 0x1500
#define ALC_STEREO_SOFT 0x1501
#define ALC_QUAD_SOFT 0x1503
#define ALC_5POINT1_SOFT 0x1504
#define ALC_6POINT1_SOFT 0x1505
#define ALC_7POINT1_SOFT 0x1506

typedef ALCdevice* (ALC_APIENTRY*LPALCLOOPBACKOPENDEVICESOFT)(const ALCchar*);
typedef ALCboolean (ALC_APIENTRY*LPALCISRENDERFORMATSUPPORTEDSOFT)(ALCdevice*,ALCsizei,ALCenum,ALCenum);
typedef void (ALC_APIENTRY*LPALCRENDERSAMPLESSOFT)(ALCdevice*,ALCvoid*,ALCsizei);
#ifdef AL_ALEXT_PROTOTYPES
ALC_API ALCdevice* ALC_APIENTRY alcLoopbackOpenDeviceSOFT(const ALCchar *deviceName);
ALC_API ALCboolean ALC_APIENTRY alcIsRenderFormatSupportedSOFT(ALCdevice *device, ALCsizei freq, ALCenum channels, ALCenum type);
ALC_API void ALC_APIENTRY alcRenderSamplesSOFT(ALCdevice *device, ALCvoid *buffer, ALCsizei samples);
#endif
#endif

#ifdef __cplusplus
}
#endif
Expand Down

0 comments on commit 60e7d26

Please sign in to comment.