bosing.OscState

class bosing.OscState(base_freq, delta_freq, phase)

基类:object

State of a channel oscillator.

参数:
  • base_freq (float) -- Base frequency of the oscillator.

  • delta_freq (float) -- Frequency shift of the oscillator.

  • phase (float) -- Phase of the oscillator in cycles.

base_freq
delta_freq
phase
phase_at(time)

Calculate the phase of the oscillator at a given time.

参数:

time (float) -- Time.

返回:

Phase of the oscillator in cycles.

返回类型:

float

total_freq()

Calculate the total frequency of the oscillator.

返回:

Total frequency of the oscillator.

返回类型:

float

with_time_shift(time)

Get a new state with a time shift.

参数:

time (float) -- Time shift.

返回:

The new state.

返回类型:

OscState