mirror of
https://github.com/lubosz/overte.git
synced 2025-08-07 20:06:02 +02:00
remove leftover listening mode, fix UUID push in InjectedAudioRingBuffer
This commit is contained in:
parent
1b129a43b5
commit
fbb097accb
4 changed files with 4 additions and 12 deletions
|
@ -82,7 +82,7 @@ void AudioMixer::addBufferToMixForListeningNodeWithBuffer(PositionalAudioRingBuf
|
||||||
stk::TwoPole* otherNodeTwoPole = NULL;
|
stk::TwoPole* otherNodeTwoPole = NULL;
|
||||||
|
|
||||||
if (bufferToAdd != listeningNodeBuffer) {
|
if (bufferToAdd != listeningNodeBuffer) {
|
||||||
// if the two buffer pointers do no match then these are different buffers
|
// if the two buffer pointers do not match then these are different buffers
|
||||||
|
|
||||||
glm::vec3 listenerPosition = listeningNodeBuffer->getPosition();
|
glm::vec3 listenerPosition = listeningNodeBuffer->getPosition();
|
||||||
glm::vec3 relativePosition = bufferToAdd->getPosition() - listeningNodeBuffer->getPosition();
|
glm::vec3 relativePosition = bufferToAdd->getPosition() - listeningNodeBuffer->getPosition();
|
||||||
|
|
|
@ -27,14 +27,6 @@ const short RING_BUFFER_LENGTH_SAMPLES = RING_BUFFER_LENGTH_FRAMES * BUFFER_LENG
|
||||||
|
|
||||||
class AudioRingBuffer : public NodeData {
|
class AudioRingBuffer : public NodeData {
|
||||||
public:
|
public:
|
||||||
|
|
||||||
static int const DEFAULT_LISTEN_LIST_SIZE = 100;
|
|
||||||
typedef enum {
|
|
||||||
NORMAL,
|
|
||||||
OMNI_DIRECTIONAL_POINT,
|
|
||||||
SELECTED_SOURCES
|
|
||||||
} ListenMode;
|
|
||||||
|
|
||||||
AudioRingBuffer(bool isStereo);
|
AudioRingBuffer(bool isStereo);
|
||||||
~AudioRingBuffer();
|
~AudioRingBuffer();
|
||||||
|
|
||||||
|
|
|
@ -25,8 +25,8 @@ InjectedAudioRingBuffer::InjectedAudioRingBuffer(const QUuid& streamIdentifier)
|
||||||
int InjectedAudioRingBuffer::parseData(unsigned char* sourceBuffer, int numBytes) {
|
int InjectedAudioRingBuffer::parseData(unsigned char* sourceBuffer, int numBytes) {
|
||||||
unsigned char* currentBuffer = sourceBuffer + numBytesForPacketHeader(sourceBuffer);
|
unsigned char* currentBuffer = sourceBuffer + numBytesForPacketHeader(sourceBuffer);
|
||||||
|
|
||||||
// push past the UUID for this injector
|
// push past the UUID for this node and the stream identifier
|
||||||
currentBuffer += NUM_BYTES_RFC4122_UUID;
|
currentBuffer += (NUM_BYTES_RFC4122_UUID * 2);
|
||||||
|
|
||||||
// use parsePositionalData in parent PostionalAudioRingBuffer class to pull common positional data
|
// use parsePositionalData in parent PostionalAudioRingBuffer class to pull common positional data
|
||||||
currentBuffer += parsePositionalData(currentBuffer, numBytes - (currentBuffer - sourceBuffer));
|
currentBuffer += parsePositionalData(currentBuffer, numBytes - (currentBuffer - sourceBuffer));
|
||||||
|
|
|
@ -70,6 +70,6 @@ bool PositionalAudioRingBuffer::shouldBeAddedToMix(int numJitterBufferSamples) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
printf("packet mismatch...\n");
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue