com.jmex.audio
Class AudioSystem

java.lang.Object
  extended by com.jmex.audio.AudioSystem
Direct Known Subclasses:
OpenALSystem

public abstract class AudioSystem
extends java.lang.Object

Main entry point for accessing the features and functionality of the com.jmex.audio package.

Version:
$Id: AudioSystem.java 4342 2009-05-13 00:45:51Z mulova $
Author:
Joshua Slack

Constructor Summary
AudioSystem()
           
 
Method Summary
 void cleanup()
           
abstract  AudioTrack createAudioTrack(java.lang.String resource, boolean stream)
           
abstract  AudioTrack createAudioTrack(java.net.URL resource, boolean stream)
           
 void fadeOutAndClear(float fadeTime)
           
abstract  Ear getEar()
           
 EnvironmentalPool getEnvironmentalPool()
           
 MusicTrackQueue getMusicQueue()
           
static AudioSystem getSystem()
          Singleton access to the audio system.
 float getUnitsPerMeter()
           
static boolean isCreated()
           
 boolean isMuted()
           
 void mute()
           
abstract  void releaseTrack(AudioTrack track)
           
abstract  void setDopplerFactor(float amount)
          Sets the degree of doppler applied.
abstract  void setMasterGain(float gain)
          Set the master volume.
abstract  void setSpeedOfSound(float unitsPerSecond)
          Sets the speed of sound using gl units per second
 void setUnitsPerMeter(float toMeterValue)
           
 void unmute()
           
abstract  void update()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AudioSystem

public AudioSystem()
Method Detail

getSystem

public static AudioSystem getSystem()
Singleton access to the audio system. FIXME: Currently hardcoded to create an openal system.

Returns:
the singleton audio system

getEar

public abstract Ear getEar()

update

public abstract void update()

createAudioTrack

public abstract AudioTrack createAudioTrack(java.net.URL resource,
                                            boolean stream)

createAudioTrack

public abstract AudioTrack createAudioTrack(java.lang.String resource,
                                            boolean stream)

releaseTrack

public abstract void releaseTrack(AudioTrack track)

mute

public void mute()

unmute

public void unmute()

setMasterGain

public abstract void setMasterGain(float gain)
Set the master volume.

Parameters:
gain - 1.0f is default.

setDopplerFactor

public abstract void setDopplerFactor(float amount)
Sets the degree of doppler applied.

Parameters:
amount - multiplying factor. 1.0f is default.

setSpeedOfSound

public abstract void setSpeedOfSound(float unitsPerSecond)
Sets the speed of sound using gl units per second

Parameters:
unitsPerSecond -

isCreated

public static boolean isCreated()

getMusicQueue

public MusicTrackQueue getMusicQueue()

getEnvironmentalPool

public EnvironmentalPool getEnvironmentalPool()

getUnitsPerMeter

public float getUnitsPerMeter()

setUnitsPerMeter

public void setUnitsPerMeter(float toMeterValue)

cleanup

public void cleanup()

fadeOutAndClear

public void fadeOutAndClear(float fadeTime)

isMuted

public boolean isMuted()