|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfootfall.generators.SoundGrainModel
Generates the sound grains used to simulate footfalls (contact, knocks, thumps etc). The sound grains are usually 25-75ms in duration, depending on the user-selected frames per second.
Constructor Summary | |
SoundGrainModel()
Provides functions for generating sound grains |
|
SoundGrainModel(int bitRate)
Provides functions for generating sound grains at specific bitrate |
Method Summary | |
int |
getBitRate()
Returns the bit rate of the sound grains. |
float[] |
makeFadingSineWave(int bytes,
int freq,
float startAmp)
Generate sine wave that starts at given volume and then fades out |
float[] |
makeWhiteNoise(int bytes,
int freq,
float maxAmp)
Generate white noise at given frequency and amplitude |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public SoundGrainModel()
public SoundGrainModel(int bitRate)
bitRate
- Specific bitRate for sound grain generation: 11.025kHz - 44.1kHzMethod Detail |
public int getBitRate()
public float[] makeFadingSineWave(int bytes, int freq, float startAmp)
bytes
- Length of the grainfreq
- Frequency of the sine wavestartAmp
- Starting amplitude of the wavepublic float[] makeWhiteNoise(int bytes, int freq, float maxAmp)
bytes
- Length of the grainfreq
- Frequency of the white noisemaxAmp
- Maximum amplitude of the white noise
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |