music.note_with_two_vibratos¶
- music.note_with_two_vibratos(freq=220, duration=2, vibrato_freq=2, secondary_vibrato_freq=6, nu1=2, nu2=4, alphav1=1, alphav2=1, waveform_table=array([-1., -0.99975586, -0.99951172, ..., -0.99926758, -0.99951172, -0.99975586], shape=(16384,)), vibrato_waveform_table=array([0., 0.0003835, 0.00076699, ..., -0.00115049, -0.00076699, -0.0003835], shape=(16384,)), sec_vibrato_waveform_table=array([0., 0.0003835, 0.00076699, ..., -0.00115049, -0.00076699, -0.0003835], shape=(16384,)), number_of_samples=0, sample_rate=44100)[source]¶
A note with a vibrato that also has a secondary oscillatory pattern.
- Parameters:
- freqscalar
The frequency of the note.
- durationscalar
The duration of the sound in seconds.
- vibrato_freqscalar
The frequency of the vibrato.
- secondary_vibrato_freqscalar
The frequency of the secondary pattern of the vibrato.
- nu1scalar
The maximum deviation of pitch in the vibrato in semitones.
- nu2scalar
The maximum deviation in semitones of pitch in the secondary pattern of the vibrato.
- alphav1scalar
An index to distort the pitch deviation of the vibrato.
- alphav2scalar
An index to distort the pitch deviation of the secondary pattern of the vibrato.
- waveform_tablearray_like
The table with the waveform to synthesize the sound.
- vibrato_waveform_tablearray_like
The table with the waveform for the vibrato oscillatory pattern.
- sec_vibrato_waveform_tablearray_like
The table with the waveform for the secondary pattern of the vibrato.
- number_of_samplesscalar
The number of samples of the sound. If supplied, duration is not used.
- sample_ratescalar
The sample rate.
- Returns:
- s
ndarray A numpy array where each value is a PCM sample of the sound.
- s
- Parameters:
- Return type:
NDArray[float64]
See also
note_with_glissando_vibratoA note with a glissando and a vibrato.
note_with_two_vibratos_glissandoA note with a glissando and a vibrato with two oscillatory patterns.
noteA basic musical note without vibrato.
note_with_vibratoA musical note with an oscillation of pitch.
tremoloA tremolo, an oscillation of loudness.
fadeFade in and out.
loudA transition of loudness.
Examples
>>> write_wav_mono(note_with_two_vibratos()) # two simultaneous vibratos >>> s = horizontal_stack( ... *[adsr(sonic_vector=note_with_two_vibratos( ... vibrato_freq=i, secondary_vibrato_freq=j)) ... for i, j in zip([2, 6, 4], [8, 10, 15])]) >>> write_wav_mono(s) # writes a file with two vibratos