aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2008-01-10 08:24:23 -0800
committerChris Robinson <[email protected]>2008-01-10 08:24:23 -0800
commitbc56c00a9a99ccbf2523ecb5f25a0e14922aed56 (patch)
tree1e4bdacf60dbb749e9958bc9417c50e6000e6744
parent1e3ad2f9ce9dcb95c76ab1e16a317d50657bba09 (diff)
Allow querying of ALC_MONO_SOURCES and ALC_STEREO_SOURCES
Based on a patch by Xavier Bouchoux
-rw-r--r--Alc/ALc.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index 1e4bca01..d33390f7 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -754,6 +754,24 @@ ALCAPI ALCvoid ALCAPIENTRY alcGetIntegerv(ALCdevice *device,ALCenum param,ALsize
*data = ALC_FALSE;
break;
+ case ALC_MONO_SOURCES:
+ if(!device || !device->Context)
+ SetALCError(ALC_INVALID_DEVICE);
+ else if (size != 1)
+ SetALCError(ALC_INVALID_VALUE);
+ else
+ *data = device->Context->lNumMonoSources;
+ break;
+
+ case ALC_STEREO_SOURCES:
+ if(!device || !device->Context)
+ SetALCError(ALC_INVALID_DEVICE);
+ else if (size != 1)
+ SetALCError(ALC_INVALID_VALUE);
+ else
+ *data = device->Context->lNumStereoSources;
+ break;
+
default:
SetALCError(ALC_INVALID_ENUM);
break;