aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2017-07-13 21:30:05 -0700
committerChris Robinson <[email protected]>2017-07-13 21:44:25 -0700
commit22d77b87a3f103eeceec004cd9d053c17bf1b883 (patch)
tree3586ee67ee3800c4df97ebc93164271b7d122dc9 /OpenAL32
parent67ab9ec4662a8d47a163426193eb962772aca23f (diff)
Store the default effect slot in the context
Diffstat (limited to 'OpenAL32')
-rw-r--r--OpenAL32/Include/alListener.h2
-rw-r--r--OpenAL32/Include/alMain.h11
2 files changed, 5 insertions, 8 deletions
diff --git a/OpenAL32/Include/alListener.h b/OpenAL32/Include/alListener.h
index 9a7f9d49..f1a92b0d 100644
--- a/OpenAL32/Include/alListener.h
+++ b/OpenAL32/Include/alListener.h
@@ -26,7 +26,7 @@ struct ALlistenerProps {
};
typedef struct ALlistener {
- ALfloat Position[3];
+ alignas(16) ALfloat Position[3];
ALfloat Velocity[3];
ALfloat Forward[3];
ALfloat Up[3];
diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h
index 6bb328e1..4081508e 100644
--- a/OpenAL32/Include/alMain.h
+++ b/OpenAL32/Include/alMain.h
@@ -798,9 +798,6 @@ struct ALCdevice_struct
*/
RefCount MixCount;
- /* Default effect slot */
- struct ALeffectslot *DefaultSlot;
-
// Contexts created on this device
ATOMIC(ALCcontext*) ContextList;
@@ -808,9 +805,6 @@ struct ALCdevice_struct
struct ALCbackend *Backend;
ALCdevice *volatile next;
-
- /* Memory space used by the default slot (Playback devices only) */
- alignas(16) ALCbyte _slot_mem[];
};
// Frequency was requested by the app or config file
@@ -872,12 +866,15 @@ struct ALCcontext_struct {
ATOMIC(struct ALeffectslotArray*) ActiveAuxSlots;
+ /* Default effect slot */
+ struct ALeffectslot *DefaultSlot;
+
ALCdevice *Device;
const ALCchar *ExtensionList;
ALCcontext *volatile next;
- /* Memory space used by the listener */
+ /* Memory space used by the listener (and possibly default effect slot) */
alignas(16) ALCbyte _listener_mem[];
};