VANetNetworkProtocol.h 31.1 KB
Newer Older
Jonas Stienen's avatar
Jonas Stienen committed
1
/*
2
 *  --------------------------------------------------------------------------------------------
Jonas Stienen's avatar
Jonas Stienen committed
3
 *
4
5
6
7
8
9
 *    VVV        VVV A           Virtual Acoustics (VA) | http://www.virtualacoustics.org
 *     VVV      VVV AAA          Licensed under the Apache License, Version 2.0
 *      VVV    VVV   AAA
 *       VVV  VVV     AAA        Copyright 2015-2017
 *        VVVVVV       AAA       Institute of Technical Acoustics (ITA)
 *         VVVV         AAA      RWTH Aachen University
Jonas Stienen's avatar
Jonas Stienen committed
10
 *
11
 *  --------------------------------------------------------------------------------------------
Jonas Stienen's avatar
Jonas Stienen committed
12
 */
13

14
15
#ifndef IW_VANET_NETWORK_PROTOCOL
#define IW_VANET_NETWORK_PROTOCOL
Jonas Stienen's avatar
Jonas Stienen committed
16

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
17
#include <VA.h>
Jonas Stienen's avatar
Jonas Stienen committed
18
19
20
21
22
23
24
25
26
27
#include <VANetDefinitions.h>

#include "VANetVistaCompatibility.h"

#include <VistaInterProcComm/Connections/VistaByteBufferSerializer.h>
#include <VistaInterProcComm/Connections/VistaByteBufferDeSerializer.h>

#include <list>
#include <string>

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
28
class CVAEvent;
Jonas Stienen's avatar
Jonas Stienen committed
29
class CVAException;
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
30
class IVAEventHandler;
Jonas Stienen's avatar
Jonas Stienen committed
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
class CVANetServerImpl;
class CVANetClientImpl;
class CVANetMessage;

class VistaConnectionIP;

/**
 * Basic implementation - non-threadsafe.
 *
 * This class implements the VA network protocol.
 *
 * The class defines the network package structure
 * and provides the necessary serialization and
 * deserialization.
 *
 * Instances of the class can only be used with one
 * purpose - either serializer and deserializer.
 *
 */
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
50
51
class CVANetNetworkProtocol
{
Jonas Stienen's avatar
Jonas Stienen committed
52
public:
53
54
	static const int VA_NET_PROTOCOL_VERSION_MAJOR = 1;
	static const int VA_NET_PROTOCOL_VERSION_MINOR = 4;
Jonas Stienen's avatar
Jonas Stienen committed
55
56
57
58
59
60
61

	/**
	 * Method identifier
	 *
	 * >>> ATTENTION!!! Never change these assignments or you end up in tears! <<<
	 */

62
	static const int VA_NP_INVALID = -1;
Jonas Stienen's avatar
Jonas Stienen committed
63

64
	static const int VA_NP_GET_VERSION_INFO = 0;
Jonas Stienen's avatar
Jonas Stienen committed
65
66

	// Base functions
67
68
69
70
	static const int VA_NP_GET_STATE = 100;
	static const int VA_NP_INITIALIZE = 101;
	static const int VA_NP_FINALIZE = 102;
	static const int VA_NP_RESET = 103;
Jonas Stienen's avatar
Jonas Stienen committed
71
72

	// Event handling   
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
73
74
	static const int VA_NP_ATTACH_EVENT_HANDLER = 201;
	static const int VA_NP_DETACH_EVENT_HANDLER = 202;
Jonas Stienen's avatar
Jonas Stienen committed
75
76

	// Module interface
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
77
	static const int VA_NP_GET_MODULES = 221;
78
	static const int VA_NP_CALL_MODULE = 222;
Jonas Stienen's avatar
Jonas Stienen committed
79
80

	// Directivities
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
81
82
	static const int VA_NP_CREATE_DIRECTIVITY = 300;
	static const int VA_NP_DELETE_DIRECTIVITY = 301;
83
84
	static const int VA_NP_GET_DIRECTIVITY_INFO = 302;
	static const int VA_NP_GET_DIRECTIVITY_INFOS = 303;
Jonas Stienen's avatar
Jonas Stienen committed
85
86

	// Head-related impulse responses (HRIRs)
87
88
89
90
91
	static const int VA_NP_LOAD_HRIR_DATASET = 400;
	static const int VA_NP_FREE_HRIR_DATASET = 401;
	static const int VA_NP_GET_HRIR_INFO = 402;
	static const int VA_NP_GET_HRIR_INFOS = 403;

Jonas Stienen's avatar
Jonas Stienen committed
92
93
	// Sounds

94
95
96
97
98
	static const int VA_NP_LOAD_SOUND = 500;
	static const int VA_NP_FREE_SOUND = 501;
	static const int VA_NP_GET_SOUND_INFO = 502;
	static const int VA_NP_GET_SOUND_INFOS = 503;
	static const int VA_NP_PLAY_SOUND = 504;
Jonas Stienen's avatar
Jonas Stienen committed
99
100
101
102


	// Signal sources

103
104
105
106
107
	static const int VA_NP_GET_SIGNALSOURCE_INFO = 600;
	static const int VA_NP_GET_SIGNALSOURCE_INFOS = 601;
	static const int VA_NP_DELETE_SIGNALSOURCE = 602;
	static const int VA_NP_GET_SIGNALSOURCE_PARAMETERS = 603;
	static const int VA_NP_SET_SIGNALSOURCE_PARAMETERS = 604;
Jonas Stienen's avatar
Jonas Stienen committed
108

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
109
	static const int VA_NP_CREATE_SIGNAL_SOURCE_BUFFER_FROM_PARAMETERS = 610;
Jonas Stienen's avatar
Jonas Stienen committed
110
111
	static const int VA_NP_GET_AUDIOFILE_SIGNALSOURCE_PLAYSTATE = 611;
	static const int VA_NP_SET_AUDIOFILE_SIGNALSOURCE_PLAYACTION = 612;
112
113
114
	static const int VA_NP_SET_AUDIOFILE_SIGNALSOURCE_PLAYPOS = 613;
	static const int VA_NP_SET_AUDIOFILE_SIGNALSOURCE_LOOPING = 614;
	static const int VA_NP_GET_AUDIOFILE_SIGNALSOURCE_LOOPING = 615;
Jonas Stienen's avatar
Jonas Stienen committed
115

116
117
118
	static const int VA_NP_CREATE_SEQUENCER_SIGNALSOURCE = 620;
	static const int VA_NP_SEQUENCER_ADD_SOUND_PLAYBACK = 621;
	static const int VA_NP_SEQUENCER_REMOVE_SOUND_PLAYBACK = 622;
Jonas Stienen's avatar
Jonas Stienen committed
119

120
	static const int VA_NP_CREATE_NETWORK_STREAM_SIGNALSOURCE = 630;
Jonas Stienen's avatar
Jonas Stienen committed
121

122
	static const int VA_NP_CREATE_ENGINE_SIGNALSOURCE = 640;
Jonas Stienen's avatar
Jonas Stienen committed
123

124
125
126
	static const int VA_NP_CREATE_MACHINE_SIGNALSOURCE = 650;

	static const int VA_NP_CREATE_TTS_SIGNAL_SOURCE = 660;
Jonas Stienen's avatar
Jonas Stienen committed
127
128
129

	// Synchronization functions

130
131
132
	static const int VA_NP_LOCK_SCENE = 700;
	static const int VA_NP_UNLOCK_SCENE = 701;
	static const int VA_NP_IS_SCENE_LOCKED = 702;
Jonas Stienen's avatar
Jonas Stienen committed
133
134

	// Sound sources
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
	static const int VA_NP_GET_SOUND_SOURCE_IDS = 800;
	static const int VA_NP_CREATE_SOUNDSOURCE = 801;
	static const int VA_NP_DELETE_SOUNDSOURCE = 802;
	static const int VA_NP_SET_SOUNDSOURCE_NAME = 803;
	static const int VA_NP_GET_SOUNDSOURCE_NAME = 804;
	static const int VA_NP_SET_SOUNDSOURCE_SIGNALSOURCE = 805;
	static const int VA_NP_GET_SOUNDSOURCE_SIGNALSOURCE = 806;
	static const int VA_NP_SET_SOUNDSOURCE_AURAMODE = 807;
	static const int VA_NP_GET_SOUNDSOURCE_AURAMODE = 808;
	static const int VA_NP_SET_SOUNDSOURCE_DIRECTIVITY = 809;
	static const int VA_NP_GET_SOUNDSOURCE_DIRECTIVITY = 810;
	static const int VA_NP_SET_SOUNDSOURCE_VOLUME = 811;
	static const int VA_NP_GET_SOUNDSOURCE_VOLUME = 812;
	static const int VA_NP_SET_SOUNDSOURCE_MUTED = 813;
	static const int VA_NP_IS_SOUNDSOURCE_MUTED = 814;
	static const int VA_NP_SET_SOUNDSOURCE_POSITION = 815;
	static const int VA_NP_GET_SOUNDSOURCE_POSITION = 816;
	static const int VA_NP_SET_SOUNDSOURCE_ORIENTATION_VU = 817;
	static const int VA_NP_GET_SOUNDSOURCE_ORIENTATION_VU = 818;
	static const int VA_NP_SET_SOUNDSOURCE_ORIENTATION_YPR = 819;
	static const int VA_NP_GET_SOUNDSOURCE_ORIENTATION_YPR = 820;
	static const int VA_NP_SET_SOUNDSOURCE_POSITION_ORIENT_VU = 821;
	static const int VA_NP_GET_SOUNDSOURCE_POSITION_ORIENT_VU = 822;
	static const int VA_NP_SET_SOUNDSOURCE_POSITION_ORIENT_YPR = 823;
	static const int VA_NP_GET_SOUNDSOURCE_POSITION_ORIENT_YPR = 824;
	static const int VA_NP_SET_SOUNDSOURCE_POSITION_ORIENT_VELOCITY_VU = 825;
	static const int VA_NP_GET_SOUNDSOURCE_POSITION_ORIENT_VELOCITY_VU = 826;
	static const int VA_NP_SET_SOUNDSOURCE_POSITION_ORIENT_VELOCITY_YPR = 827;
	static const int VA_NP_GET_SOUNDSOURCE_POSITION_ORIENT_VELOCITY_YPR = 828;
	static const int VA_NP_SET_SOUNDSOURCE_PARAMETERS = 829;
	static const int VA_NP_GET_SOUNDSOURCE_PARAMETERS = 830;
	static const int VA_NP_CREATE_SOUNDSOURCE_EXPLICIT_RENDERER = 831;
	static const int VA_NP_SET_SOUNDSOURCE_ENABLED = 832;
	static const int VA_NP_GET_SOUNDSOURCE_ENABLED = 833;
Jonas Stienen's avatar
Jonas Stienen committed
169
170

	// Listeners
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
	static const int VA_NP_GET_LISTENER_IDS = 900;
	static const int VA_NP_CREATE_LISTENER = 901;
	static const int VA_NP_DELETE_LISTENER = 902;
	static const int VA_NP_GET_LISTENER_NAME = 903;
	static const int VA_NP_SET_LISTENER_NAME = 904;
	static const int VA_NP_GET_LISTENER_AURALIZATION_MODE = 905;
	static const int VA_NP_SET_LISTENER_AURALIZATION_MODE = 906;
	static const int VA_NP_GET_LISTENER_HRIR_DATASET = 907;
	static const int VA_NP_SET_LISTENER_HRIR_DATASET = 908;
	static const int VA_NP_GET_LISTENER_POSITION = 909;
	static const int VA_NP_SET_LISTENER_POSITION = 910;
	static const int VA_NP_GET_LISTENER_ORIENTATION_VU = 911;
	static const int VA_NP_SET_LISTENER_ORIENTATION_VU = 912;
	static const int VA_NP_GET_LISTENER_ORIENTATION_YPR = 913;
	static const int VA_NP_SET_LISTENER_ORIENTATION_YPR = 914;
	static const int VA_NP_GET_LISTENER_POSITION_ORIENT_VU = 915;
	static const int VA_NP_SET_LISTENER_POSITION_ORIENT_VU = 916;
	static const int VA_NP_GET_LISTENER_POSITION_ORIENT_YPR = 917;
	static const int VA_NP_SET_LISTENER_POSITION_ORIENT_YPR = 918;
	static const int VA_NP_GET_LISTENER_POSITION_ORIENT_VELOCITY_VU = 919;
	static const int VA_NP_SET_LISTENER_POSITION_ORIENT_VELOCITY_VU = 920;
Jonas Stienen's avatar
Jonas Stienen committed
192
193
194
195
	static const int VA_NP_GET_LISTENER_POSITION_ORIENT_VELOCITY_YPR = 921;
	static const int VA_NP_SET_LISTENER_POSITION_ORIENT_VELOCITY_YPR = 922;
	static const int VA_NP_GET_LISTENER_REAL_WORLD_POSITION_ORIENT_VU = 923;
	static const int VA_NP_SET_LISTENER_REAL_WORLD_POSITION_ORIENT_VU = 924;
196
197
198
199
200
	static const int VA_NP_GET_LISTENER_PARAMETERS = 925;
	static const int VA_NP_SET_LISTENER_PARAMETERS = 926;
	static const int VA_NP_SET_LISTENER_ENABLED = 927;
	static const int VA_NP_GET_LISTENER_ENABLED = 928;
	static const int VA_NP_CREATE_LISTENER_EXPLICIT_RENDERER = 929;
Jonas Stienen's avatar
Jonas Stienen committed
201
202

	// Scene
203
204
205
206
207
208
	static const int VA_NP_LOAD_SCENE = 1000;
	static const int VA_NP_IS_SCENE_LOADED = 1001;
	static const int VA_NP_GET_SCENE_INFO = 1002;
	static const int VA_NP_GET_PORTAL_IDS = 1003;
	static const int VA_NP_GET_PORTAL_NAME = 1004;
	static const int VA_NP_SET_PORTAL_NAME = 1005;
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
209
	static const int VA_NP_GET_PORTAL_PARAMETERS = 1006;
210
	static const int VA_NP_SET_PORTAL_STATE = 1007;
Jonas Stienen's avatar
Jonas Stienen committed
211
212

	// Global functions
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
	static const int VA_NP_GET_INPUT_GAIN = 1100;
	static const int VA_NP_SET_INPUT_GAIN = 1101;
	static const int VA_NP_IS_INPUT_MUTED = 1102;
	static const int VA_NP_SET_INPUT_MUTED = 1103;
	static const int VA_NP_GET_OUTPUT_GAIN = 1104;
	static const int VA_NP_SET_OUTPUT_GAIN = 1105;
	static const int VA_NP_IS_OUTPUT_MUTED = 1106;
	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_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;
Jonas Stienen's avatar
Jonas Stienen committed
230
231

	// Global rendering methods
232
233
234
235
236
	static const int VA_NP_RENDERER_GET_INFOS = 1200;
	static const int VA_NP_RENDERER_SET_MUTED = 1201;
	static const int VA_NP_RENDERER_IS_MUTED = 1202;
	static const int VA_NP_RENDERER_GET_GAIN = 1203;
	static const int VA_NP_RENDERER_SET_GAIN = 1204;
Jonas Stienen's avatar
Jonas Stienen committed
237
238

	// Global reproduction methods
239
240
241
242
243
	static const int VA_NP_REPRODUCTION_GET_INFOS = 1300;
	static const int VA_NP_REPRODUCTION_SET_MUTED = 1301;
	static const int VA_NP_REPRODUCTION_IS_MUTED = 1302;
	static const int VA_NP_REPRODUCTION_GET_GAIN = 1303;
	static const int VA_NP_REPRODUCTION_SET_GAIN = 1304;
Jonas Stienen's avatar
Jonas Stienen committed
244
245

	// Internally used literals
246
247
	static const int VA_NP_SPECIAL_BUFFERED_MESSAGE = 42001;
	static const int VA_NP_SPECIAL_CLIENT_EVENT = 42002;
Jonas Stienen's avatar
Jonas Stienen committed
248

249
250
251
	static const int VA_NP_SPECIAL_ANSWER = 42003;
	static const int VA_NP_SPECIAL_EXCEPTION = 42004;
	static const int VA_NP_SPECIAL_NO_EXCEPTION = 42005;
Jonas Stienen's avatar
Jonas Stienen committed
252
253


254
255
256
257
	static const int VA_NET_CLIENT_CLOSE = -1001;
	static const int VA_NET_SERVER_CLOSE = -1002;
	static const int VA_NET_SERVER_RESET = -1003;
	static const int VA_NET_SERVER_DISCONNECT = -1004;
Jonas Stienen's avatar
Jonas Stienen committed
258

259
260
261
262
	static const int VA_EVENT_FAIL = 0;
	static const int VA_EVENT_CORE_EVENT = 1;
	static const int VA_EVENT_PROGRESS_UPDATE = 2;
	static const int VA_EVENT_NET_EVENT = 3;
Jonas Stienen's avatar
Jonas Stienen committed
263

264
	static const int VA_NO_EXCEPTION_INDICATOR = -31415926;
Jonas Stienen's avatar
Jonas Stienen committed
265
266
267
268

public:
	CVANetNetworkProtocol();
	virtual ~CVANetNetworkProtocol();
269

Jonas Stienen's avatar
Jonas Stienen committed
270
	bool InitializeAsServer( CVANetServerImpl* pServer );
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
271
	void SetRealVACore( IVAInterface* pRealCore );
Jonas Stienen's avatar
Jonas Stienen committed
272

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
273
274
275
276
	bool InitializeAsClient( CVANetClientImpl* pServer, VistaConnectionIP* m_pCommandChannel, VistaConnectionIP* m_pHeadChannel, const int iExceptionhandlingmode, const bool m_bBufferSynchronisedModification );
	
	int ClientProcessEventMessageFromServer( VistaConnectionIP* pConnection, std::list<IVAEventHandler*> liCoreEventHandler );
	void ServerCallFunctionByMessageType( const int nMessageType, VistaConnectionIP* pConnection );
Jonas Stienen's avatar
Jonas Stienen committed
277
	virtual bool ProcessMessageFromClient( VistaConnectionIP* pAnswerConnection );
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
278
	void ServerPrepareEventMessage( const CVAEvent* pEvent, CVANetMessage* pMessage );
Jonas Stienen's avatar
Jonas Stienen committed
279
280

	// for client side only
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
281
	virtual void SetExceptionHandlingMode( const int nMode );
Jonas Stienen's avatar
Jonas Stienen committed
282
283
284
285
286
	virtual int GetExceptionHandlingMode() const;

	virtual bool GetBufferSynchronisedModification() const;
	virtual void SetBufferSynchronisedModifications( const bool bSet );

287
288
	void HandleConnectionClose( VistaConnectionIP* pConnection );

Jonas Stienen's avatar
Jonas Stienen committed
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
private:
	enum MESSAGE_MODE
	{
		// Command Message will return an answer
		// all exceptions that occur will always be transmitted over network
		MESSAGE_WITH_ANSWER,

		// Command Message does not an return answer (no return value)
		// all exceptions that occur will always be transmitted over network
		MESSAGE_ENFORCED_EXCEPTION,

		// Command Message does not an return answer (no return value)
		// exceptions that occur will only be transmitted if the user requests
		// it on client side (configurable)
		MESSAGE_CONDITIONAL_EXCEPTION,

		// Command Message does not return an answer (no return value),
		// and also allows buffering between Begin- and End-Synchronised-Modification 
		// (if the appropriate buffering flag is set on the client).
		// All exceptions will only be transmitted if the user requests
		// it on client-side (configurable), or after the EndSynchronisedModification call
		MESSAGE_ALLOWS_BUFFERING,

		// Note: Any function that has a return value, cannot be buffered and
		//       any exceptions will be transmitted automatically.
	};

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
316
	CVANetMessage* ClientInitMessage( const int nCommanId, MESSAGE_MODE eMessageMode );
Jonas Stienen's avatar
Jonas Stienen committed
317
318
319
320
321
322
323
324
325
326
327
328
329
330
	void ClientSendCommand( CVANetMessage* pMessage );

	CVANetMessage* ServerGetMessage();
	void ServerSendAnswer( CVANetMessage* pMessage );

	void ClientPrepareMessageBuffering();
	int ClientEndMessageBuffering();

public:

	/**
	 * Client/Server actions for individual requests
	 */

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
331
	virtual void ClientGetVersionInfo( CVAVersionInfo* pVersionInfo );
Jonas Stienen's avatar
Jonas Stienen committed
332
	virtual void ServerGetVersionInfo();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
333
334
335
336
	virtual void ClientAttachEventHandler();
	virtual void ServerAttachEventHandler( VistaConnectionIP* pConn );
	virtual void ClientDetachEventHandler();
	virtual void ServerDetachEventHandler( VistaConnectionIP* pConn );
Jonas Stienen's avatar
Jonas Stienen committed
337
338
339
340
341
342
343
344
345
346
347
348
349

	virtual int ClientGetState();
	virtual void ServerGetState();

	virtual void ClientInitialize();
	virtual void ServerInitialize();

	virtual void ClientFinalize();
	virtual void ServerFinalize();

	virtual void ClientReset();
	virtual void ServerReset();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
350
351
	virtual void ClientGetModules( std::vector< CVAModuleInfo >& m_viModuleInfos );
	virtual void ServerGetModules();
Jonas Stienen's avatar
Jonas Stienen committed
352

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
353
	virtual CVAStruct ClientCallModule( const std::string& sModuleName, const CVAStruct& oArgs );
Jonas Stienen's avatar
Jonas Stienen committed
354
355
	virtual void ServerCallModule();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
356
357
	virtual int ClientCreateDirectivityFromParameters( const CVAStruct& oParams, const std::string& sName = "" );
	virtual void ServerCreateDirectivityFromParameters();
Jonas Stienen's avatar
Jonas Stienen committed
358

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
359
360
	virtual bool ClientDeleteDirectivity( const int iID );
	virtual void ServerDeleteDirectivity();
Jonas Stienen's avatar
Jonas Stienen committed
361

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
362
	virtual CVADirectivityInfo ClientGetDirectivityInfo( const int iID );
Jonas Stienen's avatar
Jonas Stienen committed
363
364
	virtual void ServerGetDirectivityInfo();

365
	virtual void ClientGetDirectivityInfos( std::vector<CVADirectivityInfo>& vdiDest );
Jonas Stienen's avatar
Jonas Stienen committed
366
	virtual void ServerGetDirectivityInfos();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
367
368
369
		
	virtual std::string ClientCreateSignalSourceBufferFromParameters( const CVAStruct& oParams, const std::string& sName = "" );
	virtual void ServerCreateSignalSourceBufferFromParameters();
370
371
372
373
374

	virtual std::string ClientCreateTextToSpeechSignalSource( const std::string& sName = "" );
	virtual void ServerCreateTextToSpeechSignalSource();

	virtual std::string ClientCreateSequencerSignalSource( const std::string& sName = "" );
Jonas Stienen's avatar
Jonas Stienen committed
375
	virtual void ServerCreateSequencerSignalSource();
376
377

	virtual std::string ClientCreateNetworkStreamSignalSource( const std::string& sInterface, int iPort, const std::string& sName = "" );
Jonas Stienen's avatar
Jonas Stienen committed
378
379
	virtual void ServerCreateNetworkStreamSignalSource();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
380
	virtual std::string ClientCreateEngineSignalSource( const CVAStruct& oParams, const std::string& sName = "" );
Jonas Stienen's avatar
Jonas Stienen committed
381
382
	virtual void ServerCreateEngineSignalSource();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
383
384
	virtual std::string ClientCreateSignalSourceMachine( const CVAStruct& oParams, const std::string& sName = "" );
	virtual void ServerCreateSignalSourceMachine();
Jonas Stienen's avatar
Jonas Stienen committed
385

386
	virtual bool ClientDeleteSignalSource( const std::string& sID );
Jonas Stienen's avatar
Jonas Stienen committed
387
388
	virtual void ServerDeleteSignalSource();

389
	virtual CVASignalSourceInfo ClientGetSignalSourceInfo( const std::string& sSignalSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
390
	virtual void ServerGetSignalSourceInfo();
391
	virtual void ClientGetSignalSourceInfos( std::vector< CVASignalSourceInfo >& vssiDest );
Jonas Stienen's avatar
Jonas Stienen committed
392
393
	virtual void ServerGetSignalSourceInfos();

394
	virtual int ClientGetAudiofileSignalSourcePlaybackState( const std::string& sSignalSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
395
396
	virtual void ServerGetAudiofileSignalSourcePlaybackState();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
397
	virtual void ClientSetAudiofileSignalSourcePlaybackAction( const std::string& sSignalSourceID, const int iPlayState );
Jonas Stienen's avatar
Jonas Stienen committed
398
399
	virtual void ServerSetAudiofileSignalSourcePlaybackAction();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
400
	virtual void ClientSetAudiofileSignalSourcePlaybackPosition( const std::string& sSignalSourceID, const double dPlaybackPosition );
Jonas Stienen's avatar
Jonas Stienen committed
401
402
	virtual void ServerSetAudiofileSignalSourcePlaybackPosition();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
403
404
405
406
	virtual bool ClientGetSignalSourceBufferLooping( const std::string& );
	virtual void ServerGetSignalSourceBufferLooping();
	virtual void ClientSetSignalSourceBufferLooping( const std::string&, const bool bLoopingEnabled );
	virtual void ServerSetSignalSourceBufferLooping();
Jonas Stienen's avatar
Jonas Stienen committed
407
408
409
410
411
412
413

	virtual	void ClientSetSignalSourceParameters( const std::string& sSignalSourceID, const CVAStruct& oParams );
	virtual	void ServerSetSignalSourceParameters();
	virtual CVAStruct ClientGetSignalSourceParameters( const std::string& sSignalSourceID, const CVAStruct& oParams );
	virtual void ServerGetSignalSourceParameters();


Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
414
415
	virtual void ClientLockUpdate();
	virtual void ServerLockUpdate();
416

Jonas Stienen's avatar
Jonas Stienen committed
417
	virtual int ClientUnlockScene();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
418
	virtual void ServerUnlockUpdate();
Jonas Stienen's avatar
Jonas Stienen committed
419

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
420
421
	virtual bool ClientGetUpdateLocked();
	virtual void ServerGetUpdateLocked();
Jonas Stienen's avatar
Jonas Stienen committed
422
423


424
	virtual void ClientGetSoundSourceIDs( std::vector<int>& vSoundSourceIDs );
Jonas Stienen's avatar
Jonas Stienen committed
425
426
	virtual void ServerGetSoundSourceIDs();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
427
	virtual int ClientCreateSoundSource( const std::string& sName );
Jonas Stienen's avatar
Jonas Stienen committed
428
429
430
431
432
	virtual void ServerCreateSoundSource();

	virtual int ClientCreateSoundSourceExplicitRenderer( const std::string& sName, const std::string& sRendererID );
	virtual void ServerCreateSoundSourceExplicitRenderer();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
433
	virtual int ClientDeleteSoundSource( const int );
Jonas Stienen's avatar
Jonas Stienen committed
434
	virtual void ServerDeleteSoundSource();
435

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
436
	virtual void ClientSetSoundSourceEnabled( const int, const bool );
Jonas Stienen's avatar
Jonas Stienen committed
437
	virtual void ServerSetSoundSourceEnabled();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
438
	virtual bool ClientGetSoundSourceEnabled( const int );
Jonas Stienen's avatar
Jonas Stienen committed
439
440
	virtual void ServerGetSoundSourceEnabled();

441
	virtual std::string ClientGetSoundSourceName( int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
442
443
	virtual void ServerGetSoundSourceName();

444
	virtual void ClientSetSoundSourceName( int iSoundSourceID, const std::string& sName );
Jonas Stienen's avatar
Jonas Stienen committed
445
446
	virtual void ServerSetSoundSourceName();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
447
	virtual std::string ClientGetSoundSourceSignalSource( const int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
448
449
	virtual void ServerGetSoundSourceSignalSource();

450
	virtual void ClientSetSoundSourceSignalSource( int iSoundSourceIDconst, const std::string& sSignalSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
451
452
	virtual void ServerSetSoundSourceSignalSource();

453
	virtual int ClientGetSoundSourceAuralizationMode( int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
454
	virtual void ServerGetSoundSourceAuralizationMode();
455
456

	virtual void ClientSetSoundSourceAuralizationMode( int iSoundSourceID, int iAuralizationMode );
Jonas Stienen's avatar
Jonas Stienen committed
457
458
459
460
461
462
463
	virtual void ServerSetSoundSourceAuralizationMode();

	virtual void ClientSetSoundSourceParameters( int iID, const CVAStruct& oParams );
	virtual void ServerSetSoundSourceParameters();

	virtual CVAStruct ClientGetSoundSourceParameters( int iID, const CVAStruct& oArgs );
	virtual void ServerGetSoundSourceParameters();
464
465

	virtual int ClientGetSoundSourceDirectivity( int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
466
467
	virtual void ServerGetSoundSourceDirectivity();

468
	virtual void ClientSetSoundSourceDirectivity( int iSoundSourceID, int iDirectivityID );
Jonas Stienen's avatar
Jonas Stienen committed
469
470
	virtual void ServerSetSoundSourceDirectivity();

471
	virtual double ClientGetSoundSourceVolume( int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
472
473
	virtual void ServerGetSoundSourceVolume();

474
	virtual void ClientSetSoundSourceVolume( int iSoundSourceID, double dGain );
Jonas Stienen's avatar
Jonas Stienen committed
475
476
	virtual void ServerSetSoundSourceVolume();

477
	virtual bool ClientIsSoundSourceMuted( int iSoundSourceID );
Jonas Stienen's avatar
Jonas Stienen committed
478
479
	virtual void ServerIsSoundSourceMuted();

480
	virtual void ClientSetSoundSourceMuted( int iSoundSourceID, bool bMuted );
Jonas Stienen's avatar
Jonas Stienen committed
481
482
	virtual void ServerSetSoundSourceMuted();

483
	virtual void ClientGetSoundSourcePosition( int iSoundSourceID, double &x, double &y, double &z );
Jonas Stienen's avatar
Jonas Stienen committed
484
485
	virtual void ServerGetSoundSourcePosition();

486
487
	virtual void ClientGetSoundSourceOrientationYPR( int iSoundSourceID,
		double& yaw, double& pitch, double& roll );
Jonas Stienen's avatar
Jonas Stienen committed
488
489
	virtual void ServerGetSoundSourceOrientationYPR();

490
491
492
493

	virtual void ClientGetSoundSourceOrientationVU( int iSoundSourceID,
		double& vx, double& vy, double& vz,
		double& ux, double& uy, double& uz );
Jonas Stienen's avatar
Jonas Stienen committed
494
495
	virtual void ServerGetSoundSourceOrientationVU();

496
497
498
499

	virtual void ClientGetSoundSourcePositionOrientationYPR( int iSoundSourceID,
		double& x, double& y, double& z,
		double& yaw, double& pitch, double& roll );
Jonas Stienen's avatar
Jonas Stienen committed
500
501
	virtual void ServerGetSoundSourcePositionOrientationYPR();

502
503
504
505
	virtual void ClientGetSoundSourcePositionOrientationVU( int iSoundSourceID,
		double& px, double& py, double& pz,
		double& vx, double& vy, double& vz,
		double& ux, double& uy, double& uz );
Jonas Stienen's avatar
Jonas Stienen committed
506
	virtual void ServerGetSoundSourcePositionOrientationVU();
507

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
508
	virtual void ClientSetSoundSourcePosition( const int iID, const VAVec3& v3Pos );
Jonas Stienen's avatar
Jonas Stienen committed
509
	virtual void ServerSetSoundSourcePosition();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
510
511
512
	virtual void ClientSetSoundSourceOrientation( const int iID, const VAQuat& qOrient );
	virtual void ServerSetSoundSourceOrientation();
	virtual void ClientSetSoundSourceOrientationVU( const int iID, const VAVec3& v3View, const VAVec3& v3Up );
Jonas Stienen's avatar
Jonas Stienen committed
513
	virtual void ServerSetSoundSourceOrientationVU();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
514
	virtual void ClientSetSoundSourcePositionOrientationVU( const int iID, const VAVec3& v3Pos, const VAVec3& v3View, const VAVec3& v3Up );
Jonas Stienen's avatar
Jonas Stienen committed
515
516
517
	virtual void ServerSetSoundSourcePositionOrientationVU();


Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
518
519
	virtual void ClientGetSoundReceiverIDs( std::vector<int>& viIDs );
	virtual void ServerGetSoundReceiverIDs();
Jonas Stienen's avatar
Jonas Stienen committed
520

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
521
522
523
524
	virtual int ClientCreateSoundReceiver( const std::string& sName );
	virtual void ServerCreateSoundReceiver();
	virtual int ClientCreateSoundReceiverExplicitRenderer( const std::string&, const std::string& );
	virtual void ServerCreateSoundReceiverExplicitRenderer();
Jonas Stienen's avatar
Jonas Stienen committed
525

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
526
527
	virtual int ClientDeleteSoundReceiver( int iListenerID );
	virtual void ServerDeleteSoundReceiver();
Jonas Stienen's avatar
Jonas Stienen committed
528
529


Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
530
531
532
533
	virtual void ClientSetSoundReceiverEnabled( const int, const bool );
	virtual void ServerSetSoundReceiverEnabled();
	virtual bool ClientGetSoundReceiverEnabled( int );
	virtual void ServerGetSoundReceiverEnabled();
Jonas Stienen's avatar
Jonas Stienen committed
534
535
536
537
538

	virtual void ClientSetActiveListenerExplicitRenderer( int, const std::string& );
	virtual void ServerSetActiveListenerExplicitRenderer();
	virtual int ClientGetActiveListenerExplicitRenderer( const std::string& );
	virtual void ServerGetActiveListenerExplicitRenderer();
539

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
540
541
	virtual std::string ClientGetSoundReceiverName( int iListenerID );
	virtual void ServerGetSoundReceiverName();
542

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
543
	virtual void ClientSetSoundReceiverName( int iID, const std::string& sName );
Jonas Stienen's avatar
Jonas Stienen committed
544
545
	virtual void ServerSetListenerName();

546
	virtual int ClientGetListenerAuralizationMode( int iListenerID );
Jonas Stienen's avatar
Jonas Stienen committed
547
548
	virtual void ServerGetListenerAuralizationMode();

549
	virtual void ClientSetListenerAuralizationMode( int iListenerID, int iAuralizationMode );
Jonas Stienen's avatar
Jonas Stienen committed
550
	virtual void ServerSetListenerAuralizationMode();
551

Jonas Stienen's avatar
Jonas Stienen committed
552
553
554
555
556
557
	virtual void ClientSetListenerParameters( int iID, const CVAStruct& oParams );
	virtual void ServerSetListenerParameters();

	virtual CVAStruct ClientGetListenerParameters( int iID, const CVAStruct& oArgs );
	virtual void ServerGetListenerParameters();

558
	virtual int ClientGetListenerHRIRDataset( int iListenerID );
Jonas Stienen's avatar
Jonas Stienen committed
559
560
	virtual void ServerGetListenerHRIRDataset();

561
	virtual void ClientSetListenerHRIRDataset( int iListenerID, int iHRIRDatasetID );
Jonas Stienen's avatar
Jonas Stienen committed
562
563
	virtual void ServerSetListenerHRIRDataset();

564
565
	virtual void ClientGetListenerPosition( int iListenerID,
		double& x, double& y, double& z );
Jonas Stienen's avatar
Jonas Stienen committed
566
567
	virtual void ServerGetListenerPosition();

568
569
	virtual void ClientGetListenerOrientationYPR( int iListenerID,
		double& yaw, double& pitch, double& roll );
Jonas Stienen's avatar
Jonas Stienen committed
570
571
	virtual void ServerGetListenerOrientationYPR();

572
573
574
	virtual void ClientGetListenerOrientationVU( int iListenerID,
		double& vx, double& vy, double& vz,
		double& ux, double& uy, double& uz );
Jonas Stienen's avatar
Jonas Stienen committed
575
576
	virtual void ServerGetListenerOrientationVU();

577
578
579
	virtual void ClientGetListenerPositionOrientationYPR( int iListenerID,
		double& x, double& y, double& z,
		double& yaw, double& pitch, double& roll );
Jonas Stienen's avatar
Jonas Stienen committed
580
581
	virtual void ServerGetListenerPositionOrientationYPR();

582
583
584
585
586

	virtual void ClientGetListenerPositionOrientationVU( int iListenerID,
		double& px, double& py, double& pz,
		double& vx, double& vy, double& vz,
		double& ux, double& uy, double& uz );
Jonas Stienen's avatar
Jonas Stienen committed
587
588
	virtual void ServerGetListenerPositionOrientationVU();

589
590
591
592
	virtual void ClientGetListenerPositionOrientationVelocityYPR( int iListenerID,
		double& dPosX, double& dPosY, double& dPosZ,
		double& dYaw, double& dPitch, double& dRoll,
		double& dVelocityX, double& dVelocityY, double& dVelocityZ );
Jonas Stienen's avatar
Jonas Stienen committed
593
594
	virtual void ServerGetListenerPositionOrientationVelocityYPR();

595
596
597
598
599
	virtual void ClientGetListenerPositionOrientationVelocityVU( int iListenerID,
		double& dPosX, double& dPosY, double& dPosZ,
		double& dViewX, double& dViewY, double& dViewZ,
		double& dUpX, double& dUpY, double& dUpZ,
		double& dVelocityX, double& dVelocityY, double& dVelocityZ );
Jonas Stienen's avatar
Jonas Stienen committed
600
601
	virtual void ServerGetListenerPositionOrientationVelocityVU();

602
603
	virtual void ClientSetListenerPosition( int iListenerID,
		double x, double y, double z );
Jonas Stienen's avatar
Jonas Stienen committed
604
605
	virtual void ServerSetListenerPosition();

606
607
	virtual void ClientSetListenerOrientationYPR( int iListenerID,
		double yaw, double pitch, double roll );
Jonas Stienen's avatar
Jonas Stienen committed
608
609
610

	virtual void ServerSetListenerOrientationYPR();

611
612
613
	virtual void ClientSetListenerOrientationVU( int iListenerID,
		double vx, double vy, double vz,
		double ux, double uy, double uz );
Jonas Stienen's avatar
Jonas Stienen committed
614
615
616

	virtual void ServerSetListenerOrientationVU();

617
618
619
	virtual void ClientSetListenerPositionOrientationYPR( int iListenerID,
		double x, double y, double z,
		double yaw, double pitch, double roll );
Jonas Stienen's avatar
Jonas Stienen committed
620
621
622

	virtual void ServerSetListenerPositionOrientationYPR();

623
624
625
626
	virtual void ClientSetListenerPositionOrientationVU( int iListenerID,
		double px, double py, double pz,
		double vx, double vy, double vz,
		double ux, double uy, double uz );
Jonas Stienen's avatar
Jonas Stienen committed
627
628
	virtual void ServerSetListenerPositionOrientationVU();

629
630
631
632
	virtual void ClientSetListenerPositionOrientationVelocityYPR( int iListenerID,
		double dPosX, double dPosY, double dPosZ,
		double dYaw, double dPitch, double dRoll,
		double dVelocityX, double dVelocityY, double dVelocityZ );
Jonas Stienen's avatar
Jonas Stienen committed
633
634
	virtual void ServerSetListenerPositionOrientationVelocityYPR();

635
636
637
638
639
	virtual void ClientSetListenerPositionOrientationVelocityVU( int iListenerID,
		double dPosX, double dPosY, double dPosZ,
		double dViewX, double dViewY, double dViewZ,
		double dUpX, double dUpY, double dUpZ,
		double dVelocityX, double dVelocityY, double dVelocityZ );
Jonas Stienen's avatar
Jonas Stienen committed
640
641
	virtual void ServerSetListenerPositionOrientationVelocityVU();

642
643
644
645
	virtual void ClientGetListenerRealWorldHeadPositionOrientationVU( int iListenerID,
		double& px, double& py, double& pz,
		double& vx, double& vy, double& vz,
		double& ux, double& uy, double& uz );
Jonas Stienen's avatar
Jonas Stienen committed
646
647
	virtual void ServerGetListenerRealWorldHeadPositionOrientationVU();

648
649
650
651
	virtual void ClientSetListenerRealWorldHeadPositionOrientationVU( int iListenerID,
		double px, double py, double pz,
		double vx, double vy, double vz,
		double ux, double uy, double uz );
Jonas Stienen's avatar
Jonas Stienen committed
652
653
654
655
656
657
658
659
660
	virtual void ServerSetListenerRealWorldHeadPositionOrientationVU();


	/* +----------------------------------------------------------+ *
	 * |                                                          | *
	 * |   Scene                                                  | *
	 * |                                                          | *
	 * +----------------------------------------------------------+ */

661
	virtual void ClientLoadScene( const std::string& sFilename );
Jonas Stienen's avatar
Jonas Stienen committed
662
663
664
665
666
667
668
669
	virtual void ServerLoadScene();

	virtual bool ClientIsSceneLoaded();
	virtual void ServerIsSceneLoaded();

	virtual CVASceneInfo ClientGetSceneInfo();
	virtual void ServerGetSceneInfo();

670
	virtual void ClientGetPortalIDs( std::vector<int>& vPortalIDs );
Jonas Stienen's avatar
Jonas Stienen committed
671
672
	virtual void ServerGetPortalIDs();

673
	virtual std::string ClientGetPortalName( int iPortalID );
Jonas Stienen's avatar
Jonas Stienen committed
674
675
	virtual void ServerGetPortalName();

676
	virtual void ClientSetPortalName( int iPortalID, const std::string& sName );
Jonas Stienen's avatar
Jonas Stienen committed
677
	virtual void ServerSetPortalName();
678

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
679
680
	virtual CVAStruct ClientGetPortalParameters( const int iPortalID );
	virtual void ServerGetPortalParameters();
Jonas Stienen's avatar
Jonas Stienen committed
681

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
682
683
	virtual void ClientSetPortalParameters( const int iPortalID, const CVAStruct& oParams );
	virtual void ServerSetPortalParameters();
Jonas Stienen's avatar
Jonas Stienen committed
684
685
686
687


	virtual double ClientGetCoreClock();
	virtual void ServerGetCoreClock();
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
688
	virtual void ClientSetCoreClock( const double dSeconds );
Jonas Stienen's avatar
Jonas Stienen committed
689
690
691
692
693
694
695
696
697
698
	virtual void ServerSetCoreClock();

	/* +----------------------------------------------------------+ *
	 * |                                                          | *
	 * |   Globals functionsn                                     | *
	 * |                                                          | *
	 * +----------------------------------------------------------+ */

	virtual double ClientGetInputGain();
	virtual void ServerGetInputGain();
699
700

	virtual void ClientSetInputGain( double dGain );
Jonas Stienen's avatar
Jonas Stienen committed
701
702
	virtual void ServerSetInputGain();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
703
704
	virtual bool ClientGetInputMuted();
	virtual void ServerGetInputMuted();
Jonas Stienen's avatar
Jonas Stienen committed
705

706
	virtual void ClientSetInputMuted( bool bMuted );
Jonas Stienen's avatar
Jonas Stienen committed
707
708
709
710
	virtual void ServerSetInputMuted();

	virtual double ClientGetOutputGain();
	virtual void ServerGetOutputGain();
711
712

	virtual void ClientSetOutputGain( double dGain );
Jonas Stienen's avatar
Jonas Stienen committed
713
714
	virtual void ServerSetOutputGain();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
715
716
	virtual bool ClientGetOutputMuted();
	virtual void ServerGetOutputMuted();
Jonas Stienen's avatar
Jonas Stienen committed
717

718
	virtual void ClientSetOutputMuted( bool bMuted );
Jonas Stienen's avatar
Jonas Stienen committed
719
720
	virtual void ServerSetOutputMuted();

721
722
	virtual int ClientGetGlobalAuralizationMode();
	virtual void ServerGetGlobalAuralizationMode();
Jonas Stienen's avatar
Jonas Stienen committed
723

724
	virtual void ClientSetGlobalAuralizationMode( int iAuralizationMode );
Jonas Stienen's avatar
Jonas Stienen committed
725
726
727
728
	virtual void ServerSetGlobalAuralizationMode();

	virtual int ClientGetActiveListener();
	virtual void ServerGetActiveListener();
729
730

	virtual void ClientSetActiveListener( int iListenerID );
Jonas Stienen's avatar
Jonas Stienen committed
731
	virtual void ServerSetActiveListener();
732
733

	virtual std::string ClientSubstituteMacros( const std::string& sStr );
Jonas Stienen's avatar
Jonas Stienen committed
734
735
	virtual void ServerSubstituteMacros();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
736
	virtual void ClientSetRenderingModuleGain( const std::string&, const double );
Jonas Stienen's avatar
Jonas Stienen committed
737
738
	virtual void ServerSetRenderingModuleGain();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
739
	virtual void ClientSetRenderingModuleMuted( const std::string&, const bool );
Jonas Stienen's avatar
Jonas Stienen committed
740
741
742
743
744
745
746
747
	virtual void ServerSetRenderingModuleMuted();

	virtual bool ClientIsRenderingModuleMuted( const std::string& );
	virtual void ServerIsRenderingModuleMuted();

	virtual double ClientGetRenderingModuleGain( const std::string& );
	virtual void ServerGetRenderingModuleGain();

748
	virtual void ClientGetRenderingModuleInfos( std::vector< CVAAudioRendererInfo >&, bool );
Jonas Stienen's avatar
Jonas Stienen committed
749
750
	virtual void ServerGetRenderingModuleInfos();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
751
	virtual void ClientSetReproductionModuleGain( const std::string&, const double );
Jonas Stienen's avatar
Jonas Stienen committed
752
753
	virtual void ServerSetReproductionModuleGain();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
754
	virtual void ClientSetReproductionModuleMuted( const std::string&, const bool );
Jonas Stienen's avatar
Jonas Stienen committed
755
756
757
758
759
760
761
762
	virtual void ServerSetReproductionModuleMuted();

	virtual bool ClientIsReproductionModuleMuted( const std::string& );
	virtual void ServerIsReproductionModuleMuted();

	virtual double ClientGetReproductionModuleGain( const std::string& );
	virtual void ServerGetReproductionModuleGain();

Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
763
	virtual void ClientGetReproductionModuleInfos( std::vector< CVAAudioReproductionInfo >&, const bool );
Jonas Stienen's avatar
Jonas Stienen committed
764
765
766
767
768
769
770
771
772
773
	virtual void ServerGetReproductionModuleInfos();


private:
	VistaConnectionIP*			m_pCommandChannel;
	VistaConnectionIP*			m_pHeadChannel;
	VistaConnectionIP*			m_pLastAnswerConnection;

	CVANetClientImpl*			m_pClient;
	CVANetServerImpl*			m_pServer;
Dipl.-Ing. Jonas Stienen's avatar
Dipl.-Ing. Jonas Stienen committed
774
	IVAInterface*					m_pRealCore;
Jonas Stienen's avatar
Jonas Stienen committed
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792

	bool						m_bBufferSynchronisedModification;
	bool						m_bBufferingActive;

	CVANetMessage*				m_pMessage;
	CVANetMessage*				m_pBufferedMessage;
	int							m_nCurrentMessageMode;

	CVANetMessage*				m_pEventMessage;
	VistaByteBufferDeSerializer	m_oIncomingEvent;
	std::vector<VANetCompat::byte>			m_vecEventBuffer;

	//VistaByteBufferSerializer	m_oHeadMessage;

	int							m_iExceptionHandlingMode;
	int							m_iReceiveTimeout;
};

793
#endif // IW_VANET_NETWORK_PROTOCOL