PageRenderTime 17ms CodeModel.GetById 11ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/indra/llaudio/lllistener.h

https://bitbucket.org/lindenlab/viewer-beta/
C++ Header | 72 lines | 33 code | 14 blank | 25 comment | 0 complexity | e11f59cf60445f5acf11ace6953c7ef8 MD5 | raw file
 1/** 
 2 * @file listener.h
 3 * @brief Description of LISTENER base class abstracting the audio support.
 4 *
 5 * $LicenseInfo:firstyear=2000&license=viewerlgpl$
 6 * Second Life Viewer Source Code
 7 * Copyright (C) 2010, Linden Research, Inc.
 8 * 
 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation;
12 * version 2.1 of the License only.
13 * 
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17 * Lesser General Public License for more details.
18 * 
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
22 * 
23 * Linden Research, Inc., 945 Battery Street, San Francisco, CA  94111  USA
24 * $/LicenseInfo$
25 */
26
27#ifndef LL_LISTENER_H
28#define LL_LISTENER_H
29
30#include "v3math.h"
31
32class LLListener 
33{
34 private:
35 protected:
36	LLVector3 mPosition;
37	LLVector3 mVelocity;
38	LLVector3 mListenAt;
39	LLVector3 mListenUp;
40
41 public:
42
43 private:
44 protected:
45 public:  
46	LLListener();
47	virtual ~LLListener();
48	virtual void init();  
49
50	virtual void set(LLVector3 pos, LLVector3 vel, LLVector3 up, LLVector3 at);
51
52	virtual void setPosition(LLVector3 pos);
53	virtual void setVelocity(LLVector3 vel);
54
55	virtual void orient(LLVector3 up, LLVector3 at);
56	virtual void translate(LLVector3 offset);
57
58	virtual void setDopplerFactor(F32 factor);
59	virtual void setRolloffFactor(F32 factor);
60
61	virtual LLVector3 getPosition();
62	virtual LLVector3 getAt();
63	virtual LLVector3 getUp();
64
65	virtual F32 getDopplerFactor();
66	virtual F32 getRolloffFactor();
67
68	virtual void commitDeferredChanges();
69};
70
71#endif
72