📄 audiodevice3d.java
字号:
* Point. The form of the position parameter matches those of the PointSound * method of the same name. * A full description of this parameter and how it is used is in * the documentation for PointSound class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample * @param position location of Point or Cone Sound in Virtual World * coordinates * @see PointSound#setPosition(float x, float y, float z) * @see PointSound#setPosition(Point3f position) */ public abstract void setPosition(int index, Point3d position); /** * Sets this sound's distance gain elliptical attenuation (not * including filter cutoff frequency) by defining corresponding * arrays containing distances from the sound's origin and gain * scale factors applied to all active positional sounds. * Gain scale factor is applied to sound based on the distance * the listener * is from sound source. * These attenuation parameters are ignored for BackgroundSound nodes. * The back attenuation parameter is ignored for PointSound nodes. * <P> * The form of the attenuation parameters match that of the ConeSound method * of the same name. * A full description of this parameter and how it is used is in * the documentation for ConeSound class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample * @param frontDistance defines an array of distance along positive axis * through which ellipses pass * @param frontAttenuationScaleFactor gain scale factors * @param backDistance defines an array of distance along the negative axis * through which ellipses pass * @param backAttenuationScaleFactor gain scale factors * @see ConeSound#setDistanceGain(float[] frontDistance, float[] frontGain, * float[] backDistance, float[] backGain) * @see ConeSound#setDistanceGain(Point2f[] frontAttenuation, * Point2f[] backAttenuation) */ public abstract void setDistanceGain(int index, double[] frontDistance, float[] frontAttenuationScaleFactor, double[] backDistance, float[] backAttenuationScaleFactor); /** * Sets this sound's direction from the local coordinate vector provided. * The form of the direction parameter matches that of the ConeSound method * of the same name. * A full description of this parameter and how it is used is in * the documentation for the ConeSound class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample * @param direction the new direction vector in local coordinates * @see ConeSound#setDirection(float x, float y, float z) * @see ConeSound#setDirection(Vector3f direction) */ public abstract void setDirection(int index, Vector3d direction); /** * Sets this sound's angular gain attenuation (including filter) * by defining corresponding arrays containing angular offsets from * the sound's axis, gain scale factors, and frequency cutoff applied * to all active directional sounds. * Gain scale factor is applied to sound based on the angle between the * sound's axis and the ray from the sound source origin to the listener. * The form of the attenuation parameter matches that of the ConeSound * method of the same name. * A full description of this parameter and how it is used is in * the documentation for the ConeSound class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample * @param filterType describes type (if any) of filtering defined by attenuation * @param angle array containing angular distances from sound axis * @param attenuationScaleFactor array containing gain scale factor * @param filterCutoff array containing filter cutoff frequencies. * The filter values for each tuples can be set to Sound.NO_FILTER. * @see ConeSound#setAngularAttenuation(float[] distance, float[] gain, * float[] filter) * @see ConeSound#setAngularAttenuation(Point3f[] attenuation) * @see ConeSound#setAngularAttenuation(Point2f[] attenuation) */ public abstract void setAngularAttenuation(int index, int filterType, double[] angle, float[] attenuationScaleFactor, float[] filterCutoff); /** * Changes the speed of sound factor. * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param rolloff atmospheric gain scale factor (changing speed of sound) * @see AuralAttributes#setRolloff */ public abstract void setRolloff(float rolloff); /** * Sets the Reflective Coefficient scale factor applied to distinct * low-order early reflections of sound off the surfaces in the region * defined by the current listening region. * <P> * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param coefficient reflection/absorption factor applied to reverb * @see AuralAttributes#setReflectionCoefficient */ public abstract void setReflectionCoefficient(float coefficient); /** * Sets the reverberation delay time. * In this form, while reverberation is being rendered, the parameter * specifies the delay time between each order of late reflections * explicitly given in milliseconds. * A value for delay time of 0.0 disables * reverberation. * <P> * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param reverbDelay time between each order of late reflection * @see AuralAttributes#setReverbDelay(float reverbDelay) */ public abstract void setReverbDelay(float reverbDelay); /** * Sets the reverberation order of reflections. * The reverbOrder parameter specifies the number of times reflections are added to * reverberation being calculated. A value of -1 specifies an unbounded * number of reverberations. * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param reverbOrder number of times reflections added to reverb signal * @see AuralAttributes#setReverbOrder */ public abstract void setReverbOrder(int reverbOrder); /** * Sets Distance Filter corresponding arrays containing distances and * frequency cutoff applied to all active positional sounds. * Gain scale factor is applied to sound based on the distance the listener * is from the sound source. * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param filterType denotes the type of filtering to be applied * @param distance array of offset distances from sound origin * @param filterCutoff array of frequency cutoff * @see AuralAttributes#setDistanceFilter(float[] distance, * float[] frequencyCutoff) * @see AuralAttributes#setDistanceFilter(Point2f[] attenuation) */ public abstract void setDistanceFilter(int filterType, double[] distance, float[] filterCutoff); /** * Specifies a scale factor applied to the frequency (or * wavelength). A value less than 1.0 will result of slowing the playback * rate of the sample. A value greater than 1.0 will increase the playback * rate. * This parameter is also used to expand or contract the usual * frequency shift applied to the sound source due to Doppler effect * calculations. Valid values are >= 0.0. * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param frequencyScaleFactor factor applied to change of frequency * @see AuralAttributes#setFrequencyScaleFactor */ public abstract void setFrequencyScaleFactor(float frequencyScaleFactor); /** * Sets the Velocity scale factor applied during Doppler Effect calculation. * This parameter specifies a scale factor applied to the velocity of sound * relative to the listener's position and movement in relation to the sound's * position and movement. This scale factor is multipled by the calculated * velocity portion of the Doppler effect equation used during sound rendering. * A full description of this parameter and how it is used is in * the documentation for the AuralAttributes class. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param velocityScaleFactor applied to velocity of sound in relation * to listener * @see AuralAttributes#setVelocityScaleFactor */ public abstract void setVelocityScaleFactor(float velocityScaleFactor); /** * Makes the sample 'play silently'. * This method implements (as efficiently as possible) the muting * of a playing sound sample. Ideally this is implemented by * stopping a sample and freeing channel resources (rather than * just setting the gain of the sample to zero). * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample */ public abstract void muteSample(int index); /** * Makes a silently playing sample audible. * In the ideal, this restarts a muted sample by offset from the * beginning by the number of milliseconds since the time the sample * began playing (rather than setting gain to current non-zero gain). * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample */ public abstract void unmuteSample(int index); /** * Temporarily stops a cached sample from playing without resetting the * sample's current pointer back to the beginning of the sound data so * that it can be unpaused at a later time from the same location in the * sample when the pause was initiated. Pausing a streaming, non-cached * sound sample will be treated as a mute. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample */ public abstract void pauseSample(int index); /** * Restarts the paused sample from the location in the sample where * paused. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample */ public abstract void unpauseSample(int index); /** * * Explicitly updates a Sample. * This method is called when a Sound is to be explicitly updated. * It is only called when all a sounds parameters are known to have * been passed to the audio device. In this way, an implementation * can choose to perform lazy-evaluation of a sample, rather than * updating the rendering state of the sample after every individual * parameter changed. * This method can be left as a null method if the implementor so chooses. * <P> * This method should only be called by Java3D Core and NOT by any application. * @param index device specific reference number to device driver sample */ public abstract void updateSample(int index);}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -