|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface AudioFactory
An AudioFactory is responsible for the initialisation of specific audio system implementations, creation of audio system specific Audio objects and any necessary clean-up operations required by a specific audio system implementation.
Each factory varies in its capabilities with regard the faithfulness of the audio rendering model (such as spatial positioning approximation), number of concurrent sounds (polyphony), hardware required, etc.
Current implemented audio systems include:
JMRI is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. See the "COPYING" file for a copy of this license.
JMRI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
| Method Summary | |
|---|---|
boolean |
audioCommandQueue(AudioCommand newAudioCommand)
Queues a new AudioCommand for subsequent execution. |
void |
cleanup()
Perform any implementation specific clean-up operations. |
AudioBuffer |
createNewBuffer(String systemName,
String userName)
Provide a specific new AudioBuffer object. |
AudioListener |
createNewListener(String systemName,
String userName)
Provide a specific new AudioListener object. |
AudioSource |
createNewSource(String systemName,
String userName)
Provide a specific new AudioSource object. |
AudioListener |
getActiveAudioListener()
Return the currently active Listener object |
Thread |
getCommandThread()
Return the currently active Command thread |
boolean |
init()
Perform any implementation specific initialisation routines. |
boolean |
isDistanceAttenuated()
Determines if this AudioFactory attenuates sources based on their distance from the Listener |
void |
setDistanceAttenuated(boolean attenuated)
Sets if this AudioFactory should attenuate sources based on their distance from the listener Default = true |
| Method Detail |
|---|
boolean init()
void cleanup()
AudioBuffer createNewBuffer(String systemName,
String userName)
systemName - for this object instanceuserName - for this object instance
AudioListener createNewListener(String systemName,
String userName)
systemName - for this object instanceuserName - for this object instance
AudioListener getActiveAudioListener()
AudioSource createNewSource(String systemName,
String userName)
systemName - for this object instanceuserName - for this object instance
boolean audioCommandQueue(AudioCommand newAudioCommand)
If newAudioCommand is null the current queue is executed and cleaned
newAudioCommand - AudioCommand to queue or null to execute queue
Thread getCommandThread()
void setDistanceAttenuated(boolean attenuated)
Default = true
attenuated - true if distance attenuation to be usedboolean isDistanceAttenuated()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||