OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 24 matching lines...) Expand all Loading... |
35 #include "wtf/Vector.h" | 35 #include "wtf/Vector.h" |
36 | 36 |
37 namespace blink { | 37 namespace blink { |
38 | 38 |
39 class HRTFDatabaseLoader; | 39 class HRTFDatabaseLoader; |
40 class PannerNode; | 40 class PannerNode; |
41 | 41 |
42 // AudioListener maintains the state of the listener in the audio scene as defin
ed in the OpenAL specification. | 42 // AudioListener maintains the state of the listener in the audio scene as defin
ed in the OpenAL specification. |
43 | 43 |
44 class AudioListener : public GarbageCollectedFinalized<AudioListener>, public Sc
riptWrappable { | 44 class AudioListener : public GarbageCollectedFinalized<AudioListener>, public Sc
riptWrappable { |
| 45 DEFINE_WRAPPERTYPEINFO(); |
45 public: | 46 public: |
46 static AudioListener* create() | 47 static AudioListener* create() |
47 { | 48 { |
48 return new AudioListener(); | 49 return new AudioListener(); |
49 } | 50 } |
50 virtual ~AudioListener(); | 51 virtual ~AudioListener(); |
51 | 52 |
52 // Position | 53 // Position |
53 void setPosition(float x, float y, float z) { setPosition(FloatPoint3D(x, y,
z)); } | 54 void setPosition(float x, float y, float z) { setPosition(FloatPoint3D(x, y,
z)); } |
54 const FloatPoint3D& position() const { return m_position; } | 55 const FloatPoint3D& position() const { return m_position; } |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 // List for pannerNodes in context. This is updated only in the main thread, | 109 // List for pannerNodes in context. This is updated only in the main thread, |
109 // and can be referred in audio thread. | 110 // and can be referred in audio thread. |
110 HeapVector<Member<PannerNode> > m_panners; | 111 HeapVector<Member<PannerNode> > m_panners; |
111 // HRTF DB loader for panner node. | 112 // HRTF DB loader for panner node. |
112 Member<HRTFDatabaseLoader> m_hrtfDatabaseLoader; | 113 Member<HRTFDatabaseLoader> m_hrtfDatabaseLoader; |
113 }; | 114 }; |
114 | 115 |
115 } // namespace blink | 116 } // namespace blink |
116 | 117 |
117 #endif // AudioListener_h | 118 #endif // AudioListener_h |
OLD | NEW |