A class implementing a noise tone stimulus.
Methods
Create a noise tone.
Parameters : | duration : int
frequency : int, optional
samplerate : int, optional
bitdepth : int, optional
amplitude : int, optional
|
---|
Getter for amplitude.
Getter for bitdepth.
Copy the stimulus.
Returns : | copy: stimulus.Audio :
|
---|
Getter for duration.
Getter for filename
Getter for id.
Getter for is_preloaded
Play the audio stimulus.
The function returns immediately after the sound started to play. A pygame.mixer.Channel object is returned.
Parameters : | loops : int, optional
maxtime : int
fade_ms : int, optional
|
---|
Preload stimulus to memory.
Presents the sound.
The function is identical to Audio.play(loops=0, maxtime=0, fade_ms=0) and returns also immediately after the sound started to play.
Notes
See Audio.play for more information.
Getter for samplerate.
Save the sine tone to a file.
Parameters : | filename : str
|
---|
Stop the audio stimulus
Unload stimulus from memory.
This removes the reference to the object in memory. It is up to the garbage collector to actually remove it from memory.