diff options
author | Chris Robinson <[email protected]> | 2022-02-08 20:43:05 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2022-02-08 20:43:05 -0800 |
commit | 256ea81dbe07f02d008908c90b99896f8eaaf2a5 (patch) | |
tree | e58348ee7808310f7c231934b91ad399c3af4d62 /core/context.h | |
parent | de87cc98d5eef40eeb565b781ac90c1c6f55b42e (diff) |
Combine listener and context updates
Diffstat (limited to 'core/context.h')
-rw-r--r-- | core/context.h | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/core/context.h b/core/context.h index f3e05689..5f1f2ae1 100644 --- a/core/context.h +++ b/core/context.h @@ -50,6 +50,13 @@ using WetBufferPtr = std::unique_ptr<WetBuffer>; struct ContextProps { + std::array<float,3> Position; + std::array<float,3> Velocity; + std::array<float,3> OrientAt; + std::array<float,3> OrientUp; + float Gain; + float MetersPerUnit; + float DopplerFactor; float DopplerVelocity; float SpeedOfSound; @@ -61,23 +68,9 @@ struct ContextProps { DEF_NEWDEL(ContextProps) }; -struct ListenerProps { - std::array<float,3> Position; - std::array<float,3> Velocity; - std::array<float,3> OrientAt; - std::array<float,3> OrientUp; - float Gain; - float MetersPerUnit; - - std::atomic<ListenerProps*> next; - - DEF_NEWDEL(ListenerProps) -}; - struct ContextParams { /* Pointer to the most recent property values that are awaiting an update. */ std::atomic<ContextProps*> ContextUpdate{nullptr}; - std::atomic<ListenerProps*> ListenerUpdate{nullptr}; alu::Vector Position{}; alu::Matrix Matrix{alu::Matrix::Identity()}; @@ -109,7 +102,6 @@ struct ContextBase { * updates. */ std::atomic<ContextProps*> mFreeContextProps{nullptr}; - std::atomic<ListenerProps*> mFreeListenerProps{nullptr}; std::atomic<VoicePropsItem*> mFreeVoiceProps{nullptr}; std::atomic<EffectSlotProps*> mFreeEffectslotProps{nullptr}; |