diff options
author | Chris Robinson <[email protected]> | 2019-08-01 09:21:56 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2019-08-01 09:21:56 -0700 |
commit | 380f3dc11de1b3d8e6a00b2920cb809cfb953c0d (patch) | |
tree | eb6f7b18750315e654da6a4c1f956b02532697d7 | |
parent | 62534f424ae0534927f948fa6cead4bdd9f73745 (diff) |
Cleanup alcontext.h includes
-rw-r--r-- | alc/alcontext.h | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/alc/alcontext.h b/alc/alcontext.h index 833d4c5b..43b9c08f 100644 --- a/alc/alcontext.h +++ b/alc/alcontext.h @@ -1,14 +1,16 @@ #ifndef ALCONTEXT_H #define ALCONTEXT_H -#include <mutex> #include <atomic> +#include <cstddef> +#include <cstdint> #include <memory> +#include <mutex> #include <thread> +#include <utility> #include "AL/al.h" #include "AL/alc.h" -#include "AL/alext.h" #include "al/listener.h" #include "almalloc.h" @@ -20,15 +22,12 @@ #include "threads.h" #include "vector.h" - -struct ALsource; struct ALeffectslot; -struct ALcontextProps; -struct ALlistenerProps; -struct ALvoiceProps; struct ALeffectslotProps; +struct ALsource; struct RingBuffer; + enum class DistanceModel { InverseClamped = AL_INVERSE_DISTANCE_CLAMPED, LinearClamped = AL_LINEAR_DISTANCE_CLAMPED, @@ -41,6 +40,19 @@ enum class DistanceModel { Default = InverseClamped }; + +struct ALcontextProps { + ALfloat DopplerFactor; + ALfloat DopplerVelocity; + ALfloat SpeedOfSound; + ALboolean SourceDistanceModel; + DistanceModel mDistanceModel; + ALfloat MetersPerUnit; + + std::atomic<ALcontextProps*> next; +}; + + struct SourceSubList { uint64_t FreeMask{~0_u64}; ALsource *Sources{nullptr}; /* 64 */ @@ -153,8 +165,7 @@ struct ALCcontext { * This does *NOT* stop mixing, but rather prevents certain property * changes from taking effect. */ - void deferUpdates() noexcept - { mDeferUpdates.store(true); } + void deferUpdates() noexcept { mDeferUpdates.store(true); } /** Resumes update processing after being deferred. */ void processUpdates(); @@ -221,18 +232,6 @@ inline bool operator<(const ContextRef &lhs, const ALCcontext *rhs) noexcept ContextRef GetContextRef(void); -struct ALcontextProps { - ALfloat DopplerFactor; - ALfloat DopplerVelocity; - ALfloat SpeedOfSound; - ALboolean SourceDistanceModel; - DistanceModel mDistanceModel; - ALfloat MetersPerUnit; - - std::atomic<ALcontextProps*> next; -}; - - extern bool TrapALError; #endif /* ALCONTEXT_H */ |