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

Removing Listener

parent 9a9e9e30
......@@ -622,18 +622,18 @@ public:
return m_pProtocol->ClientCreateSoundReceiverExplicitRenderer( sRendererID, sName );
};
inline void SetActiveListenerExplicitRenderer( const int iSoundReceiverID, const std::string& sRendererID )
inline void SetActiveSoundReceiverExplicitRenderer( const int iSoundReceiverID, const std::string& sRendererID )
{
VA_REQUIRE_CONNECTED;
VA_MUTAL_EXCLUDE;
return m_pProtocol->ClientSetActiveListenerExplicitRenderer( iSoundReceiverID, sRendererID );
return m_pProtocol->ClientSetActiveSoundReceiverExplicitRenderer( iSoundReceiverID, sRendererID );
};
inline int GetActiveListenerExplicitRenderer( const std::string& sRendererID ) const
inline int GetActiveSoundReceiverExplicitRenderer( const std::string& sRendererID ) const
{
VA_REQUIRE_CONNECTED;
VA_MUTAL_EXCLUDE;
return m_pProtocol->ClientGetActiveListenerExplicitRenderer( sRendererID );
return m_pProtocol->ClientGetActiveSoundReceiverExplicitRenderer( sRendererID );
};
inline int DeleteSoundReceiver( const int iSoundReceiverID )
......@@ -1214,18 +1214,18 @@ public:
m_pProtocol->ClientSetGlobalAuralizationMode( iAuralizationMode );
}
inline int GetActiveListener() const
inline int GetActiveSoundReceiver() const
{
VA_REQUIRE_CONNECTED;
VA_MUTAL_EXCLUDE;
return m_pProtocol->ClientGetActiveListener();
return m_pProtocol->ClientGetActiveSoundReceiver();
};
inline void SetActiveListener( const int iListenerID )
inline void SetActiveSoundReceiver( const int iID )
{
VA_REQUIRE_CONNECTED;
VA_MUTAL_EXCLUDE;
m_pProtocol->ClientSetActiveListener( iListenerID );
m_pProtocol->ClientSetActiveSoundReceiver( iID );
};
inline double GetCoreClock() const
......
......@@ -236,10 +236,10 @@ void CVANetNetworkProtocol::ServerCallFunctionByMessageType( const int nMessageT
SERVER_FUNCTION_MAPPING( VA_NP_SET_OUTPUT_MUTED, ServerSetOutputMuted() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_GLOBAL_AURALIZATION_MODE, ServerGetGlobalAuralizationMode() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_GLOBAL_AURALIZATION_MODE, ServerSetGlobalAuralizationMode() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_ACTIVE_LISTENER, ServerGetActiveListener() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_ACTIVE_LISTENER, ServerSetActiveListener() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_ACTIVE_LISTENER_EXPLICIT_RENDERER, ServerGetActiveListenerExplicitRenderer() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_ACTIVE_LISTENER_EXPLICIT_RENDERER, ServerSetActiveListenerExplicitRenderer() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_ACTIVE_SOUND_RECEIVER, ServerGetActiveSoundReceiver() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_ACTIVE_SOUND_RECEIVER, ServerSetActiveSoundReceiver() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER, ServerGetActiveSoundReceiverExplicitRenderer() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER, ServerSetActiveSoundReceiverExplicitRenderer() );
SERVER_FUNCTION_MAPPING( VA_NP_GET_CORE_CLOCK, ServerGetCoreClock() );
SERVER_FUNCTION_MAPPING( VA_NP_SET_CORE_CLOCK, ServerSetCoreClock() );
SERVER_FUNCTION_MAPPING( VA_NP_SUBSTITUTE_MACROS, ServerSubstituteMacros() );
......@@ -1962,64 +1962,64 @@ void CVANetNetworkProtocol::ServerGetSoundReceiverEnabled()
pMsg->WriteBool( bEnabled );
}
void CVANetNetworkProtocol::ClientSetActiveListenerExplicitRenderer( const int iID, const std::string& sRendererID )
void CVANetNetworkProtocol::ClientSetActiveSoundReceiverExplicitRenderer( const int iID, const std::string& sRendererID )
{
CVANetMessage* pMsg = ClientInitMessage( VA_NP_SET_ACTIVE_LISTENER_EXPLICIT_RENDERER, MESSAGE_ALLOWS_BUFFERING );
CVANetMessage* pMsg = ClientInitMessage( VA_NP_SET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER, MESSAGE_ALLOWS_BUFFERING );
pMsg->WriteInt( iID );
pMsg->WriteString( sRendererID );
ClientSendCommand( pMsg );
}
void CVANetNetworkProtocol::ServerSetActiveListenerExplicitRenderer()
void CVANetNetworkProtocol::ServerSetActiveSoundReceiverExplicitRenderer()
{
CVANetMessage* pMsg = ServerGetMessage();
int iID = pMsg->ReadInt();
std::string sRendererID = pMsg->ReadString();
m_pRealCore->SetActiveListenerExplicitRenderer( iID, sRendererID );
m_pRealCore->SetActiveSoundReceiverExplicitRenderer( iID, sRendererID );
}
int CVANetNetworkProtocol::ClientGetActiveListenerExplicitRenderer( const std::string& sRendererID )
int CVANetNetworkProtocol::ClientGetActiveSoundReceiverExplicitRenderer( const std::string& sRendererID )
{
CVANetMessage* pMsg = ClientInitMessage( VA_NP_GET_ACTIVE_LISTENER_EXPLICIT_RENDERER, MESSAGE_ALLOWS_BUFFERING );
CVANetMessage* pMsg = ClientInitMessage( VA_NP_GET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER, MESSAGE_ALLOWS_BUFFERING );
pMsg->WriteString( sRendererID );
ClientSendCommand( pMsg );
const int iID = pMsg->ReadInt();
return iID;
}
void CVANetNetworkProtocol::ServerGetActiveListenerExplicitRenderer()
void CVANetNetworkProtocol::ServerGetActiveSoundReceiverExplicitRenderer()
{
CVANetMessage* pMsg = ServerGetMessage();
const std::string sRendererID = pMsg->ReadString();
const int iID = m_pRealCore->GetActiveListenerExplicitRenderer( sRendererID );
const int iID = m_pRealCore->GetActiveSoundReceiverExplicitRenderer( sRendererID );
pMsg->WriteInt( iID );
}
void CVANetNetworkProtocol::ClientSetActiveListener( int iID )
void CVANetNetworkProtocol::ClientSetActiveSoundReceiver(const int iID )
{
CVANetMessage* pMsg = ClientInitMessage( VA_NP_SET_ACTIVE_LISTENER, MESSAGE_ALLOWS_BUFFERING );
CVANetMessage* pMsg = ClientInitMessage( VA_NP_SET_ACTIVE_SOUND_RECEIVER, MESSAGE_ALLOWS_BUFFERING );
pMsg->WriteInt( iID );
ClientSendCommand( pMsg );
}
void CVANetNetworkProtocol::ServerSetActiveListener()
void CVANetNetworkProtocol::ServerSetActiveSoundReceiver()
{
CVANetMessage* pMsg = ServerGetMessage();
const int iID = pMsg->ReadInt();
m_pRealCore->SetActiveListener( iID );
m_pRealCore->SetActiveSoundReceiver( iID );
}
int CVANetNetworkProtocol::ClientGetActiveListener()
int CVANetNetworkProtocol::ClientGetActiveSoundReceiver()
{
CVANetMessage* pMsg = ClientInitMessage( VA_NP_GET_ACTIVE_LISTENER, MESSAGE_WITH_ANSWER );
CVANetMessage* pMsg = ClientInitMessage( VA_NP_GET_ACTIVE_SOUND_RECEIVER, MESSAGE_WITH_ANSWER );
ClientSendCommand( pMsg );
return pMsg->ReadInt();
}
void CVANetNetworkProtocol::ServerGetActiveListener()
void CVANetNetworkProtocol::ServerGetActiveSoundReceiver()
{
CVANetMessage* pMsg = ServerGetMessage();
const int iID = m_pRealCore->GetActiveListener();
const int iID = m_pRealCore->GetActiveSoundReceiver();
pMsg->WriteInt( iID );
}
......
......@@ -154,7 +154,7 @@ public:
static const int VA_NP_GET_SOUND_SOURCE_GEOMETRY_MESH = 835;
static const int VA_NP_SET_SOUND_SOURCE_GEOMETRY_MESH = 836;
// Listeners
// Sound receivers
static const int VA_NP_GET_SOUND_RECEIVER_IDS = 900;
static const int VA_NP_CREATE_SOUND_RECEIVER = 901;
static const int VA_NP_CREATE_SOUND_RECEIVER_EXPLICIT_RENDERER = 929;
......@@ -272,13 +272,13 @@ public:
static const int VA_NP_SET_OUTPUT_MUTED = 1107;
static const int VA_NP_GET_GLOBAL_AURALIZATION_MODE = 1108;
static const int VA_NP_SET_GLOBAL_AURALIZATION_MODE = 1109;
static const int VA_NP_GET_ACTIVE_LISTENER = 1110;
static const int VA_NP_SET_ACTIVE_LISTENER = 1111;
static const int VA_NP_GET_ACTIVE_SOUND_RECEIVER = 1110;
static const int VA_NP_SET_ACTIVE_SOUND_RECEIVER = 1111;
static const int VA_NP_GET_CORE_CLOCK = 1112;
static const int VA_NP_SET_CORE_CLOCK = 1113;
static const int VA_NP_SUBSTITUTE_MACROS = 1114;
static const int VA_NP_GET_ACTIVE_LISTENER_EXPLICIT_RENDERER = 1115;
static const int VA_NP_SET_ACTIVE_LISTENER_EXPLICIT_RENDERER = 1116;
static const int VA_NP_GET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER = 1115;
static const int VA_NP_SET_ACTIVE_SOUND_RECEIVER_EXPLICIT_RENDERER = 1116;
// Renderers
static const int VA_NP_RENDERER_GET_INFOS = 1200;
......@@ -596,10 +596,10 @@ public:
bool ClientGetSoundReceiverEnabled( int );
void ServerGetSoundReceiverEnabled();
void ClientSetActiveListenerExplicitRenderer( int, const std::string& );
void ServerSetActiveListenerExplicitRenderer();
int ClientGetActiveListenerExplicitRenderer( const std::string& );
void ServerGetActiveListenerExplicitRenderer();
void ClientSetActiveSoundReceiverExplicitRenderer( int, const std::string& );
void ServerSetActiveSoundReceiverExplicitRenderer();
int ClientGetActiveSoundReceiverExplicitRenderer( const std::string& );
void ServerGetActiveSoundReceiverExplicitRenderer();
std::string ClientGetSoundReceiverName( const int iID );
void ServerGetSoundReceiverName();
......@@ -793,7 +793,7 @@ public:
bool ClientGetOutputMuted();
void ServerGetOutputMuted();
void ClientSetOutputMuted( bool bMuted );
void ClientSetOutputMuted( const bool bMuted );
void ServerSetOutputMuted();
int ClientGetGlobalAuralizationMode();
......@@ -802,11 +802,11 @@ public:
void ClientSetGlobalAuralizationMode( int iAuralizationMode );
void ServerSetGlobalAuralizationMode();
int ClientGetActiveListener();
void ServerGetActiveListener();
int ClientGetActiveSoundReceiver();
void ServerGetActiveSoundReceiver();
void ClientSetActiveListener( int iListenerID );
void ServerSetActiveListener();
void ClientSetActiveSoundReceiver( const int iID );
void ServerSetActiveSoundReceiver();
std::string ClientSubstituteMacros( const std::string& sStr );
void ServerSubstituteMacros();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment