From 115c39dbcff10938705c794bff1299ae7d28386e Mon Sep 17 00:00:00 2001
From: Stephen Birarda <commit@birarda.com>
Date: Thu, 6 Jun 2013 11:48:20 -0700
Subject: [PATCH] bring PHASE_DELAY_AT_90 constant above algorithim that uses
 it

---
 audio-mixer/src/main.cpp | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/audio-mixer/src/main.cpp b/audio-mixer/src/main.cpp
index 955345b942..cbe64706cd 100644
--- a/audio-mixer/src/main.cpp
+++ b/audio-mixer/src/main.cpp
@@ -124,8 +124,6 @@ int main(int argc, const char* argv[]) {
                 // zero out the client mix for this agent
                 memset(clientSamples, 0, sizeof(clientSamples));
                 
-                const int PHASE_DELAY_AT_90 = 20;
-                
                 for (AgentList::iterator otherAgent = agentList->begin(); otherAgent != agentList->end(); otherAgent++) {
                     if (((PositionalAudioRingBuffer*) otherAgent->getLinkedData())->willBeAddedToMix()
                         && (otherAgent != agent || (otherAgent == agent && agentRingBuffer->shouldLoopbackForAgent()))) {
@@ -205,6 +203,7 @@ int main(int argc, const char* argv[]) {
                                                                                   glm::normalize(rotatedSourcePosition),
                                                                                   glm::vec3(0.0f, 1.0f, 0.0f));
                                 
+                                const int PHASE_DELAY_AT_90 = 20;
                                 const float PHASE_AMPLITUDE_RATIO_AT_90 = 0.5;
                                 
                                 // figure out the number of samples of delay and the ratio of the amplitude