Mercurial > fife-parpg
comparison engine/core/audio/soundclip.h @ 378:64738befdf3b
bringing in the changes from the build_system_rework branch in preparation for the 0.3.0 release. This commit will require the Jan2010 devkit. Clients will also need to be modified to the new way to import fife.
author | vtchill@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Mon, 11 Jan 2010 23:34:52 +0000 |
parents | 3804348fe3fb |
children |
comparison
equal
deleted
inserted
replaced
377:fe6fb0e0ed23 | 378:64738befdf3b |
---|---|
64 | 64 |
65 /** Does this SoundClip require a streaming mechanism? | 65 /** Does this SoundClip require a streaming mechanism? |
66 * | 66 * |
67 * @return Returns true if streaming is required, false if not. | 67 * @return Returns true if streaming is required, false if not. |
68 */ | 68 */ |
69 bool isStream() { | 69 bool isStream() const { |
70 return m_isstream; | 70 return m_isstream; |
71 } | 71 } |
72 | 72 |
73 /** Returns the number of buffers used by the SoundClip | 73 /** Returns the number of buffers used by the SoundClip |
74 * (only for non-streaming sound clips) | 74 * (only for non-streaming sound clips) |
75 * | 75 * |
76 * @return Returns the number of buffers. | 76 * @return Returns the number of buffers. |
77 */ | 77 */ |
78 unsigned int countBuffers() { | 78 unsigned int countBuffers() const { |
79 return m_buffervec.at(0)->usedbufs; | 79 return m_buffervec.at(0)->usedbufs; |
80 } | 80 } |
81 | 81 |
82 /** Returns the array of buffers for queuing | 82 /** Returns the array of buffers for queuing |
83 * | 83 * |
84 */ | 84 */ |
85 ALuint* getBuffers(unsigned int streamid = 0) { | 85 ALuint* getBuffers(unsigned int streamid = 0) const { |
86 return m_buffervec.at(streamid)->buffers; | 86 return m_buffervec.at(streamid)->buffers; |
87 } | 87 } |
88 | 88 |
89 /** Starts streaming the soundclip | 89 /** Starts streaming the soundclip |
90 * @return Returns the streamid | 90 * @return Returns the streamid |
102 */ | 102 */ |
103 bool setStreamPos(unsigned int streamid, SoundPositionType type, float value); | 103 bool setStreamPos(unsigned int streamid, SoundPositionType type, float value); |
104 | 104 |
105 /** Gets the stream position | 105 /** Gets the stream position |
106 */ | 106 */ |
107 float getStreamPos(unsigned int streamid, SoundPositionType type); | 107 float getStreamPos(unsigned int streamid, SoundPositionType type) const; |
108 | 108 |
109 /** Refill a processed buffer with new data | 109 /** Refill a processed buffer with new data |
110 * | 110 * |
111 * @return True if file was EOF | 111 * @return True if file was EOF |
112 * @param streamid The stream ID | 112 * @param streamid The stream ID |
127 // return m_refcount; | 127 // return m_refcount; |
128 // } | 128 // } |
129 | 129 |
130 /** Returns the attached decoder | 130 /** Returns the attached decoder |
131 */ | 131 */ |
132 SoundDecoder* getDecoder() { | 132 SoundDecoder* getDecoder() const { |
133 return m_decoder; | 133 return m_decoder; |
134 } | 134 } |
135 | 135 |
136 private: | 136 private: |
137 //unsigned int m_refcount; // Reference count of that soundclip | 137 //unsigned int m_refcount; // Reference count of that soundclip |