Commit dd8bc9e3 authored by Dipl.-Ing. Jonas Stienen's avatar Dipl.-Ing. Jonas Stienen
Browse files

Huge preproc renaming

parent c63f8dce
......@@ -144,8 +144,8 @@ if( NOT DEFINED ITA_VACORE_WITH_RENDERER_BINAURAL_AIR_TRAFFIC_NOISE )
set( ITA_VACORE_WITH_RENDERER_BINAURAL_AIR_TRAFFIC_NOISE ON CACHE BOOL "Build VACore with rendering module: air traffic noise (VATSS)" )
endif( )
if( NOT DEFINED ITA_VACORE_WITH_RENDERER_MONAURAL_FREE_FIELD )
set( ITA_VACORE_WITH_RENDERER_MONAURAL_FREE_FIELD ON CACHE BOOL "Build VACore with rendering module: monaural free-field" )
if( NOT DEFINED ITA_VACORE_WITH_RENDERER_PROTOTYPE_FREE_FIELD )
set( ITA_VACORE_WITH_RENDERER_PROTOTYPE_FREE_FIELD ON CACHE BOOL "Build VACore with rendering module: prototype free-field" )
endif( )
if( NOT DEFINED ITA_VACORE_WITH_RENDERER_PROTOTYPE_DUMMY )
......@@ -224,14 +224,14 @@ add_definitions( "-DVACORE_DEFAULT_LOG_LEVEL=${ITA_VACORE_DEFAULT_DEBUG_LEVEL}"
add_definitions( "-DVACORE_VERSION_MAJOR=\"${ITA_VACORE_VERSION_MAJOR}\"" )
add_definitions( "-DVACORE_VERSION_MINOR=\"${ITA_VACORE_VERSION_MINOR}\"" )
if( ${ITA_VACORE_MODULE_INTERFACE_ENABLED} )
add_definitions( "-DVACORE_MODULE_INTERFACE_ENABLED=1" )
if( ITA_VACORE_MODULE_INTERFACE_ENABLED )
add_definitions( "-DVACORE_MODULE_INTERFACE_ENABLED" )
endif( )
if( ${ITA_VACORE_NO_MODULE_INTERFACE_THROW_EXCEPTION} )
add_definitions( "-DVACORE_NO_MODULE_INTERFACE_THROW_EXCEPTION=1" )
if( ITA_VACORE_NO_MODULE_INTERFACE_THROW_EXCEPTION )
add_definitions( "-DVACORE_NO_MODULE_INTERFACE_THROW_EXCEPTION" )
endif( )
if( ${ITA_VACORE_EVENTS_ENABLED} )
add_definitions( "-DVACORE_EVENTS_ENABLED=1" )
if( ITA_VACORE_EVENTS_ENABLED )
add_definitions( "-DVACORE_EVENTS_ENABLED" )
endif( )
add_definitions( "-DVACORE_DEFAULT_CONFIGFILE=\"${ITA_VACORE_DEFAULT_CONFIG_FILE_NAME}\"" )
......@@ -249,66 +249,66 @@ if( ITA_VACORE_WITH_AUDIO_BACKEND_DUMMY )
endif( )
# Rendering definitions
if( ${ITA_VACORE_WITH_RENDERER_AMBIENT_MIXER} )
add_definitions( "-DVACORE_WITH_RENDERER_AMBIENT_MIXER=1" )
if( ITA_VACORE_WITH_RENDERER_AMBIENT_MIXER )
add_definitions( "-DVACORE_WITH_RENDERER_AMBIENT_MIXER" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD} )
add_definitions( "-DVACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD=1" )
if( ITA_VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD )
add_definitions( "-DVACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD} )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_FREE_FIELD=1" )
if( ITA_VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_FREE_FIELD" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB} )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB=1" )
if( ITA_VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_BINAURAL_ROOM_ACOUSTICS} )
if( ITA_VACORE_WITH_RENDERER_BINAURAL_ROOM_ACOUSTICS )
if( RAVENNET_FOUND )
vista_use_package( RavenNet REQUIRED FIND_DEPENDENCIES )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_ROOM_ACOUSTICS=1" )
else( RAVENNET_FOUND )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_ROOM_ACOUSTICS" )
else( )
message( "Could not find RavenNet, which is required by binaural room acoustics audio renderer" )
endif( RAVENNET_FOUND )
endif( )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_BINAURAL_AIR_TRAFFIC_NOISE} )
if( ITA_VACORE_WITH_RENDERER_BINAURAL_AIR_TRAFFIC_NOISE )
add_definitions( "-DVACORE_WITH_RENDERER_BINAURAL_AIR_TRAFFIC_NOISE" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_MONAURAL_FREE_FIELD} )
add_definitions( "-DVACORE_WITH_RENDERER_MONAURAL_FREE_FIELD=1" )
if( ITA_VACORE_WITH_RENDERER_PROTOTYPE_FREE_FIELD )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_FREE_FIELD" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_PROTOTYPE_DUMMY} )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_DUMMY=1" )
if( ITA_VACORE_WITH_RENDERER_PROTOTYPE_DUMMY )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_DUMMY" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_PROTOTYPE_HEARING_AID} )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_HEARING_AID=1" )
if( ITA_VACORE_WITH_RENDERER_PROTOTYPE_HEARING_AID )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_HEARING_AID" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_PROTOTYPE_GENERIC_PATH} )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_GENERIC_PATH=1" )
if( ITA_VACORE_WITH_RENDERER_PROTOTYPE_GENERIC_PATH )
add_definitions( "-DVACORE_WITH_RENDERER_PROTOTYPE_GENERIC_PATH" )
endif( )
if( ${ITA_VACORE_WITH_RENDERER_VBAP_FREE_FIELD} )
add_definitions( "-DVACORE_WITH_RENDERER_VBAP_FREE_FIELD=1" )
if( ITA_VACORE_WITH_RENDERER_VBAP_FREE_FIELD )
add_definitions( "-DVACORE_WITH_RENDERER_VBAP_FREE_FIELD" )
endif( )
# Reproduction definitions
if( ${ITA_VACORE_WITH_REPRODUCTION_TALKTHROUGH} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_TALKTHROUGH=1" )
if( ITA_VACORE_WITH_REPRODUCTION_TALKTHROUGH )
add_definitions( "-DVACORE_WITH_REPRODUCTION_TALKTHROUGH" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_HEADPHONES} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_HEADPHONES=1" )
if( ITA_VACORE_WITH_REPRODUCTION_HEADPHONES )
add_definitions( "-DVACORE_WITH_REPRODUCTION_HEADPHONES" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_AMBISONICS} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_AMBISONICS=1" )
if( ITA_VACORE_WITH_REPRODUCTION_AMBISONICS )
add_definitions( "-DVACORE_WITH_REPRODUCTION_AMBISONICS" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_BINAURAL_NCTC} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_BINAURAL_NCTC=1" )
if( ITA_VACORE_WITH_REPRODUCTION_BINAURAL_NCTC )
add_definitions( "-DVACORE_WITH_REPRODUCTION_BINAURAL_NCTC" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_BINAURAL_MIXDOWN} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_BINAURAL_MIXDOWN=1" )
if( ITA_VACORE_WITH_REPRODUCTION_BINAURAL_MIXDOWN )
add_definitions( "-DVACORE_WITH_REPRODUCTION_BINAURAL_MIXDOWN" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_AMBISONICS_BINAURAL_MIXDOWN} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_AMBISONICS_BINAURAL_MIXDOWN=1" )
if( ITA_VACORE_WITH_REPRODUCTION_AMBISONICS_BINAURAL_MIXDOWN )
add_definitions( "-DVACORE_WITH_REPRODUCTION_AMBISONICS_BINAURAL_MIXDOWN" )
endif( )
if( ${ITA_VACORE_WITH_REPRODUCTION_MIXER_LOW_FREQUENCY} )
add_definitions( "-DVACORE_WITH_REPRODUCTION_MIXER_LOW_FREQUENCY=1" )
if( ITA_VACORE_WITH_REPRODUCTION_MIXER_LOW_FREQUENCY )
add_definitions( "-DVACORE_WITH_REPRODUCTION_MIXER_LOW_FREQUENCY" )
endif( )
string( TIMESTAMP VACORE_CMAKE_DATE "%Y-%m-%d" )
......
......@@ -29,7 +29,7 @@
#include <assert.h>
#include <string>
#if( VACORE_WITH_RENDERER_AMBIENT_MIXER == 1 )
#ifdef VACORE_WITH_RENDERER_AMBIENT_MIXER == 1 )
CVAAmbientMixerAudioRenderer::CVAAmbientMixerAudioRenderer( const CVAAudioRendererInitParams& oParams_ )
: m_oParams( oParams_ )
......
......@@ -14,7 +14,7 @@
#ifndef IW_VACORE_AMBIENT_MIXER_AUDIO_RENDERER
#define IW_VACORE_AMBIENT_MIXER_AUDIO_RENDERER
#if( VACORE_WITH_RENDERER_AMBIENT_MIXER == 1 )
#ifdef VACORE_WITH_RENDERER_AMBIENT_MIXER
// VA includes
#include "../../VAAudioRenderer.h"
......@@ -55,6 +55,6 @@ private:
CVAAmbientMixerAudioRenderer operator=( const CVAAmbientMixerAudioRenderer & ) { VA_EXCEPT_NOT_IMPLEMENTED; };
};
#endif // ( VACORE_WITH_RENDERER_AMBIENT_MIXER == 1 )
#endif // VACORE_WITH_RENDERER_AMBIENT_MIXER
#endif // IW_VACORE_AMBIENT_MIXER_AUDIO_RENDERER
......@@ -13,7 +13,7 @@
#include "VAAmbisonicsFreefieldAudioRenderer.h"
#if ( VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD == 1 )
#ifdef VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD
// VA includes
#include "../../../directivities/VADirectivity.h"
......@@ -547,7 +547,7 @@ void CVAAmbisonicsFreeFieldAudioRenderer::ManageSoundPaths( const CVASceneState*
while( citr != pDiff->viNewReceiverIDs.end() )
{
const int& iID( *citr++ );
CVAAFFListener* pListener = CreateListener( iID, pNewScene->GetListenerState( iID ) );
CVAAFFListener* pListener = CreateListener( iID, pNewScene->GetReceiverState( iID ) );
}
// New paths: (1) new receivers, current sources
......@@ -584,9 +584,9 @@ void CVAAmbisonicsFreeFieldAudioRenderer::ManageSoundPaths( const CVASceneState*
continue; // Explicit source is not connected to this renderer
CVAAFFSource* pSource = it->second;
for( size_t i = 0; i < pDiff->viComListenerIDs.size(); i++ )
for( size_t i = 0; i < pDiff->viComReceiverIDs.size(); i++ )
{
int iListenerID = pDiff->viComListenerIDs[ i ];
int iListenerID = pDiff->viComReceiverIDs[ i ];
CVAAFFListener* pListener = m_mListeners[ iListenerID ];
if( !pListener->bDeleted )
CVAAFFSoundPath* pPath = CreateSoundPath( pSource, pListener );
......@@ -672,7 +672,7 @@ void CVAAmbisonicsFreeFieldAudioRenderer::HandleProcessStream( ITADatasourceReal
while( spit != ctxAudio.m_lSoundPaths.end() )
{
CVAAFFSoundPath* pPath( *spit );
CVAListenerState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( pPath->pListener->pData->iID ) : NULL );
CVAReceiverState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( pPath->pListener->pData->iID ) : NULL );
CVASoundSourceState* pSourceState = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( pPath->pSource->pData->iID ) : NULL );
if( pListenerState == nullptr || pSourceState == nullptr )
......@@ -812,8 +812,8 @@ void CVAAmbisonicsFreeFieldAudioRenderer::UpdateTrajectories()
int iListenerID = it->first;
CVAAFFListener* pListener = it->second;
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
const CVAMotionState* pMotionCur = ( pListenerCur ? pListenerCur->GetMotionState() : nullptr );
const CVAMotionState* pMotionNew = ( pListenerNew ? pListenerNew->GetMotionState() : nullptr );
......@@ -871,7 +871,7 @@ CVAAFFSoundPath* CVAAmbisonicsFreeFieldAudioRenderer::CreateSoundPath( CVAAFFSou
if( pSourceNew != nullptr )
pPath->oDirectivityStateNew.pData = ( IVADirectivity* ) pSourceNew->GetDirectivityData();
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
//if (pListenerNew != nullptr)
// pPath->oHRIRStateNew.pData = (IVAHRIRDataset*)pListenerNew->GetHRIRDataset();
......@@ -890,7 +890,7 @@ void CVAAmbisonicsFreeFieldAudioRenderer::DeleteSoundPath( CVAAFFSoundPath* pPat
m_pUpdateMessage->vDelPaths.push_back( pPath );
}
CVAAmbisonicsFreeFieldAudioRenderer::CVAAFFListener* CVAAmbisonicsFreeFieldAudioRenderer::CreateListener( const int iID, const CVAListenerState* pListenerState )
CVAAmbisonicsFreeFieldAudioRenderer::CVAAFFListener* CVAAmbisonicsFreeFieldAudioRenderer::CreateListener( const int iID, const CVAReceiverState* pListenerState )
{
VA_VERBOSE( "AmbisonicsFreeFieldAudioRenderer", "Creating listener with ID " << iID );
......@@ -1093,8 +1093,8 @@ void CVAAmbisonicsFreeFieldAudioRenderer::UpdateSoundPaths()
CVASoundSourceState* pSourceCur = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVASoundSourceState* pSourceNew = ( m_pNewSceneState ? m_pNewSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
if( pSourceNew == nullptr )
{
......@@ -1372,5 +1372,4 @@ int CVAAmbisonicsFreeFieldAudioRenderer::GetIndex( int m, int n )
return ( n*n + n + m );
}
#endif // ( VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD == 1 )
#endif // VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD
......@@ -14,7 +14,7 @@
#ifndef IW_VACORE_AMBISONICSFREEFIELDAUDIORENDERER
#define IW_VACORE_AMBISONICSFREEFIELDAUDIORENDERER
#if( VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD == 1 )
#ifdef VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD
// VA includes
#include "../../../Motion/VAMotionModelBase.h"
......@@ -350,7 +350,7 @@ private:
const CVASceneState* pNewScene,
const CVASceneStateDiff* pDiff );
void UpdateSources();
CVAAFFListener* CreateListener( int iID, const CVAListenerState* );
CVAAFFListener* CreateListener( int iID, const CVAReceiverState* );
void DeleteListener( int iID );
CVAAFFSource* CreateSource( int iID, const CVASoundSourceState* );
void DeleteSource( int iID );
......@@ -370,6 +370,6 @@ private:
friend class CVAAFFSourcePoolFactory;
};
#endif // ( VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD==1 )
#endif // VACORE_WITH_RENDERER_AMBISONICS_FREE_FIELD
#endif // IW_VACORE_AmbisonicsFREEFIELDAUDIORENDERER
......@@ -596,7 +596,7 @@ void CVABinauralAirTrafficNoiseAudioRenderer::ManageSoundPaths( const CVASceneSt
while( citr != pDiff->viNewReceiverIDs.end() )
{
const int& iID( *citr++ );
CVABATNSoundReceiver* pListener = CreateSoundReceiver( iID, pNewScene->GetListenerState( iID ) );
CVABATNSoundReceiver* pListener = CreateSoundReceiver( iID, pNewScene->GetReceiverState( iID ) );
}
// New paths: (1) new receivers, current sources
......@@ -633,9 +633,9 @@ void CVABinauralAirTrafficNoiseAudioRenderer::ManageSoundPaths( const CVASceneSt
if( pSoundSourceDesc->sExplicitRendererID.empty() || pSoundSourceDesc->sExplicitRendererID == m_oParams.sID )
bForThisRenderer = true;
for( size_t i = 0; i < pDiff->viComListenerIDs.size(); i++ )
for( size_t i = 0; i < pDiff->viComReceiverIDs.size(); i++ )
{
int iListenerID = pDiff->viComListenerIDs[ i ];
int iListenerID = pDiff->viComReceiverIDs[ i ];
CVABATNSoundReceiver* pListener = m_mListeners[ iListenerID ];
if( !pListener->bDeleted && bForThisRenderer )
......@@ -710,7 +710,7 @@ void CVABinauralAirTrafficNoiseAudioRenderer::ProcessStream( const ITAStreamInfo
while( spit != ctxAudio.m_lSoundPaths.end() )
{
CVABATNSoundPath* pPath( *spit );
CVAListenerState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( pPath->pSoundReceiver->pData->iID ) : NULL );
CVAReceiverState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( pPath->pSoundReceiver->pData->iID ) : NULL );
CVASoundSourceState* pSourceState = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( pPath->pSoundSource->pData->iID ) : NULL );
if( pListenerState == nullptr || pSourceState == nullptr )
......@@ -916,8 +916,8 @@ void CVABinauralAirTrafficNoiseAudioRenderer::UpdateTrajectories()
int iListenerID = it->first;
CVABATNSoundReceiver* pListener = it->second;
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
const CVAMotionState* pMotionCur = ( pListenerCur ? pListenerCur->GetMotionState() : nullptr );
const CVAMotionState* pMotionNew = ( pListenerNew ? pListenerNew->GetMotionState() : nullptr );
......@@ -978,7 +978,7 @@ CVABATNSoundPath* CVABinauralAirTrafficNoiseAudioRenderer::CreateSoundPath( CVAB
pPath->oRefSoundPath.oDirectivityStateNew.pData = ( IVADirectivity* ) pSourceNew->GetDirectivityData();
}
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
if( pListenerNew != nullptr )
{
pPath->oDirSoundPath.oSoundReceiverDirectivityStateNew.pData = ( IVADirectivity* ) pListenerNew->GetDirectivity();
......@@ -1000,7 +1000,7 @@ void CVABinauralAirTrafficNoiseAudioRenderer::DeleteSoundPath( CVABATNSoundPath*
m_pUpdateMessage->vDelPaths.push_back( pPath );
}
CVABinauralAirTrafficNoiseAudioRenderer::CVABATNSoundReceiver* CVABinauralAirTrafficNoiseAudioRenderer::CreateSoundReceiver( int iID, const CVAListenerState* pListenerState )
CVABinauralAirTrafficNoiseAudioRenderer::CVABATNSoundReceiver* CVABinauralAirTrafficNoiseAudioRenderer::CreateSoundReceiver( int iID, const CVAReceiverState* pListenerState )
{
VA_VERBOSE( "BinauralAirTrafficNoiseAudioRenderer", "Creating listener with ID " << iID );
......@@ -1190,8 +1190,8 @@ void CVABinauralAirTrafficNoiseAudioRenderer::UpdateSoundPaths()
CVASoundSourceState* pSourceCur = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVASoundSourceState* pSourceNew = ( m_pNewSceneState ? m_pNewSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
if( pSourceNew == nullptr )
{
......
......@@ -295,7 +295,7 @@ private:
void ManageSoundPaths( const CVASceneState* pCurScene, const CVASceneState* pNewScene, const CVASceneStateDiff* pDiff );
void UpdateSources();
CVABATNSoundReceiver* CreateSoundReceiver( int iID, const CVAListenerState* );
CVABATNSoundReceiver* CreateSoundReceiver( int iID, const CVAReceiverState* );
void DeleteListener( int iID );
CVABATNSource* CreateSoundSource( int iID, const CVASoundSourceState* );
void DeleteSource( int iID );
......
......@@ -13,7 +13,7 @@
#include "VABinauralArtificialReverb.h"
#if ( VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB == 1 )
#ifdef VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB
// VA includes
#include "../../../directivities/VADirectivityDAFFEnergetic.h"
......@@ -701,10 +701,10 @@ void CVABinauralArtificialReverbAudioRenderer::ManageArtificialReverbPaths( cons
Source* pSource = CreateSource( iSourceID );
// Aktuelle Hrer
for( int i = 0; i < ( int ) pDiff->viComListenerIDs.size(); i++ )
for( int i = 0; i < ( int ) pDiff->viComReceiverIDs.size(); i++ )
{
// Neuen Pfad erzeugen zu neuer Quelle
int iListenerID = pDiff->viComListenerIDs[ i ];
int iListenerID = pDiff->viComReceiverIDs[ i ];
Listener* pListener = m_mListener[ iListenerID ];
CreateArtificialReverbPath( pSource, pListener );
}
......@@ -754,7 +754,7 @@ void CVABinauralArtificialReverbAudioRenderer::ProcessStream( const ITAStreamInf
{
CBARPath* pPath( *apit );
CVAListenerState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( pPath->pListener->pData->iID ) : NULL );
CVAReceiverState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( pPath->pListener->pData->iID ) : NULL );
CVASoundSourceState* pSourceState = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( pPath->pSource->pData->iID ) : NULL );
if( pListenerState == nullptr || pSourceState == nullptr )
......@@ -823,7 +823,7 @@ void CVABinauralArtificialReverbAudioRenderer::ProcessStream( const ITAStreamInf
while( lit != m_mListener.end() )
{
Listener* pListener = lit->second;
CVAListenerState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( pListener->pData->iID ) : NULL );
CVAReceiverState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( pListener->pData->iID ) : NULL );
const float* pfIn = pListener->psbInput->data();
float* pfOutL = ( *pListener->psfOutput )[ 0 ].data();
......@@ -896,8 +896,8 @@ void CVABinauralArtificialReverbAudioRenderer::UpdateTrajectories()
int iListenerID = lit->first;
Listener* pListener = lit->second;
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
const CVAMotionState* pMotionCur = ( pListenerCur ? pListenerCur->GetMotionState() : nullptr );
const CVAMotionState* pMotionNew = ( pListenerNew ? pListenerNew->GetMotionState() : nullptr );
......@@ -1156,8 +1156,8 @@ void CVABinauralArtificialReverbAudioRenderer::UpdateArtificialReverbPaths( cons
int iID = lcit->first;
Listener* pListener( lcit->second );
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iID ) : NULL );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iID ) : NULL );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iID ) : NULL );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iID ) : NULL );
// New or none HRIR triggers AR update for the listener of this path
if( pListenerNew == nullptr )
......@@ -1465,4 +1465,4 @@ void CBARPath::UpdateMetrics()
oRelations.Calc( pSource->vPredPos, pSource->vPredView, pSource->vPredUp, pListener->vPredPos, pListener->vPredView, pListener->vPredUp );
}
#endif // ( VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB == 1 )
#endif // VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB
......@@ -25,7 +25,7 @@
#ifndef IW_VACORE_BINAURALARTIFICIALREVERBDAUDIORENDERER
#define IW_VACORE_BINAURALARTIFICIALREVERBDAUDIORENDERER
#if( VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB == 1 )
#ifdef VACORE_WITH_RENDERER_BINAURAL_ARTIFICIAL_REVERB == 1 )
// VA includes
#include <VA.h>
......
......@@ -13,7 +13,7 @@
#include "VABinauralFreefieldAudioRenderer.h"
#if ( VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD == 1 )
#ifdef VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD
// VA includes
#include <VA.h>
......@@ -158,7 +158,7 @@ public:
void UpdateDir( bool bDIRAuraModeEnabled );
void UpdateMediumPropagation( double dSpeedOfSound, double dAdditionalDelaySeconds = 0.0f );
double CalculateInverseDistanceDecrease() const;
void UpdateHRIR( const CVAListenerState::CVAAnthropometricParameter& );
void UpdateHRIR( const CVAReceiverState::CVAAnthropometricParameter& );
//! Bestimmt die relativen Gren des Pfades
/**
......@@ -553,7 +553,7 @@ void CVABinauralFreeFieldAudioRenderer::ManageSoundPaths( const CVASceneState* p
while( citr != pDiff->viNewReceiverIDs.end() )
{
const int& iID( *citr++ );
CVABFFListener* pListener = CreateListener( iID, pNewScene->GetListenerState( iID ) );
CVABFFListener* pListener = CreateListener( iID, pNewScene->GetReceiverState( iID ) );
}
// New paths: (1) new receivers, current sources
......@@ -590,9 +590,9 @@ void CVABinauralFreeFieldAudioRenderer::ManageSoundPaths( const CVASceneState* p
continue; // Explicit source is not connected to this renderer
CVABFFSource* pSource = it->second;
for( size_t i = 0; i < pDiff->viComListenerIDs.size(); i++ )
for( size_t i = 0; i < pDiff->viComReceiverIDs.size(); i++ )
{
int iListenerID = pDiff->viComListenerIDs[ i ];
int iListenerID = pDiff->viComReceiverIDs[ i ];
CVABFFListener* pListener = m_mListeners[ iListenerID ];
if( !pListener->bDeleted )
CVABFFSoundPath* pPath = CreateSoundPath( pSource, pListener );
......@@ -673,7 +673,7 @@ void CVABinauralFreeFieldAudioRenderer::ProcessStream( const ITAStreamInfo* pStr
while( spit != ctxAudio.m_lSoundPaths.end() )
{
CVABFFSoundPath* pPath( *spit );
CVAListenerState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( pPath->pListener->pData->iID ) : NULL );
CVAReceiverState* pListenerState = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( pPath->pListener->pData->iID ) : NULL );
CVASoundSourceState* pSourceState = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( pPath->pSource->pData->iID ) : NULL );
if( pListenerState == nullptr || pSourceState == nullptr )
......@@ -808,8 +808,8 @@ void CVABinauralFreeFieldAudioRenderer::UpdateTrajectories()
int iListenerID = it->first;
CVABFFListener* pListener = it->second;
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
const CVAMotionState* pMotionCur = ( pListenerCur ? pListenerCur->GetMotionState() : nullptr );
const CVAMotionState* pMotionNew = ( pListenerNew ? pListenerNew->GetMotionState() : nullptr );
......@@ -867,7 +867,7 @@ CVABFFSoundPath* CVABinauralFreeFieldAudioRenderer::CreateSoundPath( CVABFFSourc
if( pSourceNew != nullptr )
pPath->oDirectivityStateNew.pData = ( IVADirectivity* ) pSourceNew->GetDirectivityData();
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
if( pListenerNew != nullptr )
pPath->oHRIRStateNew.pData = ( IVADirectivity* ) pListenerNew->GetDirectivity();
......@@ -891,7 +891,7 @@ void CVABinauralFreeFieldAudioRenderer::DeleteSoundPath( CVABFFSoundPath* pPath
m_pUpdateMessage->vDelPaths.push_back( pPath );
}
CVABinauralFreeFieldAudioRenderer::CVABFFListener* CVABinauralFreeFieldAudioRenderer::CreateListener( const int iID, const CVAListenerState* pListenerState )
CVABinauralFreeFieldAudioRenderer::CVABFFListener* CVABinauralFreeFieldAudioRenderer::CreateListener( const int iID, const CVAReceiverState* pListenerState )
{
VA_VERBOSE( "BinauralFreeFieldAudioRenderer", "Creating listener with ID " << iID );
......@@ -1094,8 +1094,8 @@ void CVABinauralFreeFieldAudioRenderer::UpdateSoundPaths()
CVASoundSourceState* pSourceCur = ( m_pCurSceneState ? m_pCurSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVASoundSourceState* pSourceNew = ( m_pNewSceneState ? m_pNewSceneState->GetSoundSourceState( iSourceID ) : nullptr );
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
if( pSourceNew == nullptr )
{
......@@ -1255,7 +1255,7 @@ double CVABFFSoundPath::CalculateInverseDistanceDecrease() const
return fInverseDistanceDecrease;
}
void CVABFFSoundPath::UpdateHRIR( const CVAListenerState::CVAAnthropometricParameter& oAnthroParameters )
void CVABFFSoundPath::UpdateHRIR( const CVAReceiverState::CVAAnthropometricParameter& oAnthroParameters )
{
CVADirectivityDAFFHRIR* pHRIRDataNew = ( CVADirectivityDAFFHRIR * ) oHRIRStateNew.pData;
bool bForeUpdate = false;
......@@ -1422,4 +1422,4 @@ void CVABinauralFreeFieldAudioRenderer::onStopDumpListeners()
m_bDumpListeners = false;
}
#endif // ( VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD == 1 )
#endif // VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD
......@@ -15,7 +15,7 @@
#ifndef IW_VACORE_BINAURALFREEFIELDAUDIORENDERER
#define IW_VACORE_BINAURALFREEFIELDAUDIORENDERER
#if( VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD == 1 )
#ifdef VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD
#include <VA.h>
......@@ -343,7 +343,7 @@ private:
void ManageSoundPaths( const CVASceneState* pCurScene, const CVASceneState* pNewScene, const CVASceneStateDiff* pDiff );
void UpdateSources();
CVABFFListener* CreateListener( int iID, const CVAListenerState* );
CVABFFListener* CreateListener( int iID, const CVAReceiverState* );
void DeleteListener( int iID );
CVABFFSource* CreateSource( int iID, const CVASoundSourceState* );
void DeleteSource( int iID );
......@@ -366,6 +366,6 @@ private:
CVABinauralFreeFieldAudioRenderer operator=( const CVABinauralFreeFieldAudioRenderer & ) { VA_EXCEPT_NOT_IMPLEMENTED; };
};
#endif // ( VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD==1 )
#endif // ( VACORE_WITH_RENDERER_BINAURAL_FREE_FIELD
#endif // IW_VACORE_BINAURALFREEFIELDAUDIORENDERER
......@@ -1531,10 +1531,10 @@ void CVARoomAcousticsAudioRenderer::ManageComplexSoundPaths( const CVASceneState
Source* pSource = CreateSource( iSourceID );
// Aktuelle Hrer
for( int i = 0; i < ( int ) pDiff->viComListenerIDs.size(); i++ )
for( int i = 0; i < ( int ) pDiff->viComReceiverIDs.size(); i++ )
{
// Neuen Pfad erzeugen zu neuer Quelle
int iListenerID = pDiff->viComListenerIDs[ i ];
int iListenerID = pDiff->viComReceiverIDs[ i ];
Listener* pListener = m_mListener[ iListenerID ];
ComplexSoundPath* pPath = CreateComplexSoundPath( pSource, pListener );
}
......@@ -1581,8 +1581,8 @@ void CVARoomAcousticsAudioRenderer::UpdateTrajectories()
int iListenerID = it->first;
Listener* pListener = it->second;
CVAListenerState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetListenerState( iListenerID ) : nullptr );
CVAListenerState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetListenerState( iListenerID ) : nullptr );
CVAReceiverState* pListenerCur = ( m_pCurSceneState ? m_pCurSceneState->GetReceiverState( iListenerID ) : nullptr );
CVAReceiverState* pListenerNew = ( m_pNewSceneState ? m_pNewSceneState->GetReceiverState( iListenerID ) : nullptr );
const CVAMotionState* pMotionCur = ( pListenerCur ? pListenerCur->GetMotionState() : nullptr );
const CVAMotionState* pMotionNew = ( pListenerNew ? pListenerNew->GetMotionState() : nullptr );
......@@ -1939,7 +1939,7 @@ ComplexSoundPath* CVARoomAcousticsAudioRenderer::CreateComplexSoundPath( Source*
// Auralisierungsmodus
CVASoundSourceState* pSourceCur = ( m_pCurSceneState ? m_pCurSceneState