From 256ea81dbe07f02d008908c90b99896f8eaaf2a5 Mon Sep 17 00:00:00 2001
From: Chris Robinson <chris.kcat@gmail.com>
Date: Tue, 8 Feb 2022 20:43:05 -0800
Subject: Combine listener and context updates

---
 core/context.h | 22 +++++++---------------
 1 file changed, 7 insertions(+), 15 deletions(-)

(limited to 'core/context.h')

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};
 
-- 
cgit v1.2.3