|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectzombie.core.sound.Stream
public class Stream
A sound wave that is streamed from an input stream.
| Field Summary | |
|---|---|
boolean |
bPreserve
|
| Constructor Summary | |
|---|---|
Stream()
C'tor |
|
Stream(java.lang.String url,
float gain,
float pitch,
int priority,
boolean looped)
C'tor. |
|
Stream(java.lang.String url,
float gain,
float pitch,
int priority,
boolean looped,
Attenuator attenuator)
C'tor |
|
Stream(java.lang.String url,
int priority)
C'tor. |
|
Stream(java.lang.String url,
int priority,
boolean looped)
C'tor. |
|
| Method Summary | |
|---|---|
void |
create()
Creates this Stream. |
void |
create(boolean bPreserve)
|
void |
destroy()
Destroys this instance and any resources it holds. |
Attenuator |
getAttenuator()
Returns the Attenuator to use for this Sound. |
int |
getFormat()
|
float |
getGain()
Returns the gain. |
StreamInstance |
getInstance(zombie.core.sound.Source source)
get or create a stream instance from our pool |
float |
getPitch()
Returns the pitch. |
int |
getPriority()
Returns the priority. |
java.lang.String |
getURL()
|
boolean |
isCreated()
|
boolean |
isLooped()
Returns looped status |
boolean |
isStereo()
|
void |
setAttenuator(Attenuator attenuator)
Sets the Attenuator to use for this Sound. |
void |
setGain(float gain)
Sets the default gain for this buffer |
void |
setLooped(boolean looped)
Sets whether this buffer should be looped by default |
void |
setPitch(float pitch)
Sets the default pitch for this buffer |
void |
setPriority(int priority)
Sets the default priority for this buffer relative to all other buffers. |
void |
setURL(java.lang.String url)
Sets the URL from where this AbstractSound will read Ogg Vorbis data |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public boolean bPreserve
| Constructor Detail |
|---|
public Stream()
public Stream(java.lang.String url,
int priority)
url - priority -
public Stream(java.lang.String url,
int priority,
boolean looped)
url - priority - looped -
public Stream(java.lang.String url,
float gain,
float pitch,
int priority,
boolean looped)
url - gain - pitch - priority - looped -
public Stream(java.lang.String url,
float gain,
float pitch,
int priority,
boolean looped,
Attenuator attenuator)
url - gain - pitch - priority - looped - attenuator - | Method Detail |
|---|
public void create()
AL is not created, or if this Stream is already created, does nothing.
destroy()public void create(boolean bPreserve)
public void destroy()
create()public boolean isCreated()
public int getFormat()
public boolean isStereo()
public java.lang.String toString()
toString in class java.lang.Objectpublic StreamInstance getInstance(zombie.core.sound.Source source)
public final void setGain(float gain)
Sound
setGain in interface Soundgain - (must be ≥ 0.0f and ≤ 1.0f)public final void setPitch(float pitch)
Sound
setPitch in interface Soundpitch - (must be > 0.0f)public final void setPriority(int priority)
Sound
setPriority in interface Soundpriority - (must be >= 0)public final void setLooped(boolean looped)
Sound
setLooped in interface Soundpublic final void setURL(java.lang.String url)
Sound
setURL in interface Soundurl - May ne nullpublic final float getGain()
Sound
getGain in interface Soundpublic final float getPitch()
Sound
getPitch in interface Soundpublic final int getPriority()
Sound
getPriority in interface Soundpublic final boolean isLooped()
Sound
isLooped in interface Soundpublic final java.lang.String getURL()
getURL in interface Soundpublic Attenuator getAttenuator()
SoundAttenuator to use for this Sound. The default Attenuator is specified by the SoundEngine itself,
so if no attenuator has been set with Sound.setAttenuator(Attenuator) then the default returned by
SoundEngine.getDefaultAttenuator() will be used instead when playing the sound.
getAttenuator in interface SoundSound.setAttenuator(Attenuator),
SoundEngine.getDefaultAttenuator()public void setAttenuator(Attenuator attenuator)
SoundAttenuator to use for this Sound. If set to null, then the default attenuator as returned by
SoundEngine.getDefaultAttenuator() will be used when playing this sound.
setAttenuator in interface Soundattenuator - May be nullSound.getAttenuator(),
SoundEngine.getDefaultAttenuator()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||