|
|
@ -17,7 +17,7 @@ public interface AudioSource { |
|
|
|
public enum Status { |
|
|
|
public enum Status { |
|
|
|
/** |
|
|
|
/** |
|
|
|
* The audio source is currently playing. This will be set if |
|
|
|
* The audio source is currently playing. This will be set if |
|
|
|
* {@link AudioSource#play() } is called. |
|
|
|
* {@link AudioNode#play()} is called. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
Playing, |
|
|
|
Playing, |
|
|
|
|
|
|
|
|
|
|
@ -28,7 +28,7 @@ public interface AudioSource { |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* The audio source is currently stopped. |
|
|
|
* The audio source is currently stopped. |
|
|
|
* This will be set if {@link AudioSource#stop() } is called |
|
|
|
* This will be set if {@link AudioNode#stop()} is called |
|
|
|
* or the audio has reached the end of the file. |
|
|
|
* or the audio has reached the end of the file. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
Stopped, |
|
|
|
Stopped, |
|
|
@ -47,13 +47,13 @@ public interface AudioSource { |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The {#link Filter dry filter} that is set. |
|
|
|
* @return The {#link Filter dry filter} that is set. |
|
|
|
* @see AudioSource#setDryFilter(com.jme3.audio.Filter) |
|
|
|
* @see AudioNode#setDryFilter(com.jme3.audio.Filter) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Filter getDryFilter(); |
|
|
|
public Filter getDryFilter(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The {@link AudioData} set previously with |
|
|
|
* @return The {@link AudioData} set previously with |
|
|
|
* {@link AudioSource#setAudioData(com.jme3.audio.AudioData, com.jme3.audio.AudioKey) } |
|
|
|
* {@link AudioNode#setAudioData(com.jme3.audio.AudioData, com.jme3.audio.AudioKey)} |
|
|
|
* or any of the constructors that initialize the audio data. |
|
|
|
* or any of the constructors that initialize the audio data. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public AudioData getAudioData(); |
|
|
|
public AudioData getAudioData(); |
|
|
@ -65,34 +65,34 @@ public interface AudioSource { |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The {@link Status} of the audio source. |
|
|
|
* @return The {@link Status} of the audio source. |
|
|
|
* The status will be changed when either the {@link AudioSource#play() } |
|
|
|
* The status will be changed when either the {@link AudioNode#play()} |
|
|
|
* or {@link AudioSource#stop() } methods are called. |
|
|
|
* or {@link AudioNode#stop()} methods are called. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Status getStatus(); |
|
|
|
public Status getStatus(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return True if the audio will keep looping after it is done playing, |
|
|
|
* @return True if the audio will keep looping after it is done playing, |
|
|
|
* otherwise, false. |
|
|
|
* otherwise, false. |
|
|
|
* @see AudioSource#setLooping(boolean) |
|
|
|
* @see AudioNode#setLooping(boolean) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isLooping(); |
|
|
|
public boolean isLooping(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The pitch of the audio, also the speed of playback. |
|
|
|
* @return The pitch of the audio, also the speed of playback. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setPitch(float) |
|
|
|
* @see AudioNode#setPitch(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getPitch(); |
|
|
|
public float getPitch(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The volume of this audio source. |
|
|
|
* @return The volume of this audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setVolume(float) |
|
|
|
* @see AudioNode#setVolume(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getVolume(); |
|
|
|
public float getVolume(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return the time offset in the sound sample when to start playing. |
|
|
|
* @return the time offset in the sound sample to start playing |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getTimeOffset(); |
|
|
|
public float getTimeOffset(); |
|
|
|
|
|
|
|
|
|
|
@ -102,79 +102,77 @@ public interface AudioSource { |
|
|
|
public float getPlaybackTime(); |
|
|
|
public float getPlaybackTime(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The velocity of the audio source. |
|
|
|
* @return The position of the audio source. |
|
|
|
* |
|
|
|
|
|
|
|
* @see AudioSource#setVelocity(com.jme3.math.Vector3f) |
|
|
|
|
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Vector3f getPosition(); |
|
|
|
public Vector3f getPosition(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The velocity of the audio source. |
|
|
|
* @return The velocity of the audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setVelocity(com.jme3.math.Vector3f) |
|
|
|
* @see AudioNode#setVelocity(com.jme3.math.Vector3f) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Vector3f getVelocity(); |
|
|
|
public Vector3f getVelocity(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return True if reverb is enabled, otherwise false. |
|
|
|
* @return True if reverb is enabled, otherwise false. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setReverbEnabled(boolean) |
|
|
|
* @see AudioNode#setReverbEnabled(boolean) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isReverbEnabled(); |
|
|
|
public boolean isReverbEnabled(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return Filter for the reverberations of this audio source. |
|
|
|
* @return Filter for the reverberations of this audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setReverbFilter(com.jme3.audio.Filter) |
|
|
|
* @see AudioNode#setReverbFilter(com.jme3.audio.Filter) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Filter getReverbFilter(); |
|
|
|
public Filter getReverbFilter(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return Max distance for this audio source. |
|
|
|
* @return Max distance for this audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setMaxDistance(float) |
|
|
|
* @see AudioNode#setMaxDistance(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getMaxDistance(); |
|
|
|
public float getMaxDistance(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The reference playing distance for the audio source. |
|
|
|
* @return The reference playing distance for the audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setRefDistance(float) |
|
|
|
* @see AudioNode#setRefDistance(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getRefDistance(); |
|
|
|
public float getRefDistance(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return True if the audio source is directional |
|
|
|
* @return True if the audio source is directional |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setDirectional(boolean) |
|
|
|
* @see AudioNode#setDirectional(boolean) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isDirectional(); |
|
|
|
public boolean isDirectional(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The direction of this audio source. |
|
|
|
* @return The direction of this audio source. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setDirection(com.jme3.math.Vector3f) |
|
|
|
* @see AudioNode#setDirection(com.jme3.math.Vector3f) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Vector3f getDirection(); |
|
|
|
public Vector3f getDirection(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The directional audio source, cone inner angle. |
|
|
|
* @return The directional audio source, cone inner angle. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setInnerAngle(float) |
|
|
|
* @see AudioNode#setInnerAngle(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getInnerAngle(); |
|
|
|
public float getInnerAngle(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return The directional audio source, cone outer angle. |
|
|
|
* @return The directional audio source, cone outer angle. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setOuterAngle(float) |
|
|
|
* @see AudioNode#setOuterAngle(float) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public float getOuterAngle(); |
|
|
|
public float getOuterAngle(); |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* @return True if the audio source is positional. |
|
|
|
* @return True if the audio source is positional. |
|
|
|
* |
|
|
|
* |
|
|
|
* @see AudioSource#setPositional(boolean) |
|
|
|
* @see AudioNode#setPositional(boolean) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isPositional(); |
|
|
|
public boolean isPositional(); |
|
|
|
|
|
|
|
|
|
|
|