public class JavaSoundMixer extends AudioEngine3DL2
| Constructor and Description |
|---|
JavaSoundMixer(org.jogamp.java3d.PhysicalEnvironment physicalEnvironment) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearSound(int index)
Clears the fields associated with sample data for this sound.
|
boolean |
close()
Code to close the device.
|
int |
getNumberOfChannelsUsed(int index)
Get number of channels used by a particular sample on the audio device.
|
int |
getNumberOfChannelsUsed(int index,
boolean muted)
Overriden method from AudioEngine3D.
|
long |
getSampleDuration(int index)
Get length of time a sample would play if allowed to play to completion.
|
long |
getStartTime(int index)
Get time this sample begun playing on the audio device.
|
int |
getTotalChannels()
Query total number of channels available for sound rendering
for this audio device.
|
boolean |
initialize()
Code to initialize the device
New interface to mixer/engine specific methods
|
void |
muteSample(int index)
Mute sample.
|
void |
pause()
Pauses audio device engine without closing the device and associated
threads.
|
void |
pauseSample(int index)
Pause sample.
|
int |
prepareSound(int soundType,
org.jogamp.java3d.MediaContainer soundData)
Code to load sound data into a channel of device mixer.
|
void |
resume()
Resumes audio device engine (if previously paused) without reinitializing * the device.
|
void |
setDirection(int index,
org.jogamp.vecmath.Vector3d direction)
Set direction vector of sample.
|
void |
setGain(float scaleFactor)
Set overall gain control of all sounds playing on the audio device.
|
void |
setLoop(int index,
int count)
Set number of times sample is looped.
|
void |
setPosition(int index,
org.jogamp.vecmath.Point3d position)
Set location of sample.
|
void |
setRateScaleFactor(int index,
float rateScaleFactor)
Set scale factor applied to sample playback rate for a particular sound
associated with the audio device.
|
void |
setReflectionCoefficient(float coefficient)
Set reverberation surface reflection coefficient value for current aural
attribute applied to all samples.
|
void |
setReverbDelay(float reverbDelay)
Set reverberation delay time for current aural attribute applied to
all samples.
|
void |
setReverbOrder(int reverbOrder)
Set reverberation order for current aural attribute applied to all
samples.
|
void |
setVworldXfrm(int index,
org.jogamp.java3d.Transform3D trans)
Save a reference to the local to virtual world coordinate space
Overriden method from AudioEngine3D.
|
int |
startSample(int index)
Start sample playing on audio device
|
int |
stopSample(int index)
Stop sample playing on audio device
|
void |
unmuteSample(int index)
Unmute sample.
|
void |
unpauseSample(int index)
Unpause sample.
|
void |
updateSample(int index)
Update sample.
|
setDecayFilter, setDecayTime, setDensity, setDiffusion, setObstructionFilter, setObstructionGain, setOcclusionFilter, setOcclusionGain, setReflectionDelay, setReverbCoefficientgetAuralParameters, getSample, getSampleListSize, getView, setAngularAttenuation, setDistanceFilter, setDistanceGain, setFrequencyScaleFactor, setRolloff, setSampleGain, setVelocityScaleFactor, setViewgetAngleOffsetToSpeaker, getAudioPlaybackType, getCenterEarToSpeaker, getChannelsAvailable, getChannelsUsedForSound, setAngleOffsetToSpeaker, setAudioPlaybackType, setCenterEarToSpeakerequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitpublic JavaSoundMixer(org.jogamp.java3d.PhysicalEnvironment physicalEnvironment)
public int getTotalChannels()
getTotalChannels in interface org.jogamp.java3d.AudioDevicegetTotalChannels in class AudioEnginepublic boolean initialize()
initialize in interface org.jogamp.java3d.AudioDeviceinitialize in class AudioEnginepublic boolean close()
close in interface org.jogamp.java3d.AudioDeviceclose in class AudioEnginepublic int prepareSound(int soundType,
org.jogamp.java3d.MediaContainer soundData)
prepareSound in interface org.jogamp.java3d.AudioDevice3DprepareSound in class AudioEngine3DsoundType - denotes type of sound: Background, Point or ConesoundData - descrition of sound source datapublic void clearSound(int index)
clearSound in interface org.jogamp.java3d.AudioDevice3DclearSound in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void setVworldXfrm(int index,
org.jogamp.java3d.Transform3D trans)
setVworldXfrm in interface org.jogamp.java3d.AudioDevice3DsetVworldXfrm in class AudioEngine3Dindex - device specific reference number to device driver sampletrans - is a reference to virtual world composite transformpublic void setPosition(int index,
org.jogamp.vecmath.Point3d position)
AudioEngine3DsetPosition in interface org.jogamp.java3d.AudioDevice3DsetPosition in class AudioEngine3Dindex - device specific reference number to device driver sampleposition - point location in virtual world coordinate of samplepublic void setDirection(int index,
org.jogamp.vecmath.Vector3d direction)
AudioEngine3DsetDirection in interface org.jogamp.java3d.AudioDevice3DsetDirection in class AudioEngine3Dindex - device specific reference number to device driver sampledirection - vector in virtual world coordinate.public void setReflectionCoefficient(float coefficient)
AudioEngine3DsetReflectionCoefficient in interface org.jogamp.java3d.AudioDevice3DsetReflectionCoefficient in class AudioEngine3Dcoefficient - applied to amplitude of reverbation added at each
iteration of reverb processing.public void setReverbDelay(float reverbDelay)
AudioEngine3DsetReverbDelay in interface org.jogamp.java3d.AudioDevice3DsetReverbDelay in class AudioEngine3DreverbDelay - amount of time in millisecond between each
iteration of reverb processing.public void setReverbOrder(int reverbOrder)
AudioEngine3DsetReverbOrder in interface org.jogamp.java3d.AudioDevice3DsetReverbOrder in class AudioEngine3DreverbOrder - number of times reverb process loop is iterated.public int startSample(int index)
AudioEngine3DstartSample in interface org.jogamp.java3d.AudioDevice3DstartSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic int stopSample(int index)
AudioEngine3DstopSample in interface org.jogamp.java3d.AudioDevice3DstopSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void pauseSample(int index)
AudioEngine3DpauseSample in interface org.jogamp.java3d.AudioDevice3DpauseSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void unpauseSample(int index)
AudioEngine3DunpauseSample in interface org.jogamp.java3d.AudioDevice3DunpauseSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void updateSample(int index)
AudioEngine3DupdateSample in interface org.jogamp.java3d.AudioDevice3DupdateSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void muteSample(int index)
AudioEngine3DmuteSample in interface org.jogamp.java3d.AudioDevice3DmuteSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void unmuteSample(int index)
AudioEngine3DunmuteSample in interface org.jogamp.java3d.AudioDevice3DunmuteSample in class AudioEngine3Dindex - device specific reference number to device driver samplepublic long getSampleDuration(int index)
AudioEngine3DgetSampleDuration in interface org.jogamp.java3d.AudioDevice3DgetSampleDuration in class AudioEngine3Dindex - device specific reference number to device driver samplepublic int getNumberOfChannelsUsed(int index)
AudioEngine3DgetNumberOfChannelsUsed in interface org.jogamp.java3d.AudioDevice3DgetNumberOfChannelsUsed in class AudioEngine3Dindex - device specific reference number to device driver samplepublic int getNumberOfChannelsUsed(int index,
boolean muted)
getNumberOfChannelsUsed in interface org.jogamp.java3d.AudioDevice3DgetNumberOfChannelsUsed in class AudioEngine3Dindex - device specific reference number to device driver samplemuted - denotes the mute state to assume while executing this
query. This mute value does not have to match the current mute state
of the sample.public long getStartTime(int index)
AudioEngine3DgetStartTime in interface org.jogamp.java3d.AudioDevice3DgetStartTime in class AudioEngine3Dindex - device specific reference number to device driver samplepublic void setLoop(int index,
int count)
AudioEngine3DsetLoop in interface org.jogamp.java3d.AudioDevice3DsetLoop in class AudioEngine3Dindex - device specific reference number to device driver samplecount - number of times sample is repeatedpublic void setGain(float scaleFactor)
AudioEngine3DL2setGain in interface org.jogamp.java3d.AudioDevice3DL2setGain in class AudioEngine3DL2scaleFactor - scale factor applied to calculated amplitudes for
all sounds playing on this devicepublic void setRateScaleFactor(int index,
float rateScaleFactor)
AudioEngine3DL2setRateScaleFactor in interface org.jogamp.java3d.AudioDevice3DL2setRateScaleFactor in class AudioEngine3DL2index - device specific reference to device driver samplerateScaleFactor - non-negative factor applied to calculated
amplitudes for all sounds playing on this deviceSound.setRateScaleFactor(float)public void pause()
pause in interface org.jogamp.java3d.AudioDevice3DL2pause in class AudioEngine3DL2public void resume()
resume in interface org.jogamp.java3d.AudioDevice3DL2resume in class AudioEngine3DL2