Audio.Param
Audio parameters.
module Automation_rate : sig ... end
Automation rate enumeration.
The type for AudioParamDescriptor
objects.
val descriptor :
?automation_rate:Automation_rate.t ->
?min_value:float ->
?max_value:float ->
?default_value:float ->
Jstr.t ->
descriptor
create name
is an audio parameter descriptor with given properties.
The type for AudioParam
objects.
val automation_rate : t -> Automation_rate.t
automation_rate p
is the automation rate of p
.
val set_automation_rate : t -> Automation_rate.t -> unit
set_automation_rate p r
sets the automation_rate
of p
to r
.
val default_value : t -> float
default_value p
is the default value of p
.
val min_value : t -> float
min_value p
is the minimal value of p
.
val max_value : t -> float
max_value p
is the maximal value of p
.
val set_value_at_time : t -> value:float -> time:float -> unit
set_value_at_time p ~value ~time
sets p
's value to value
at time time
.
val linear_ramp_to_value_at_time : t -> value:float -> end_time:float -> unit
linear_ramp_to_value_at_time p ~value ~end_time
sets p
's value to value
at time end_time
by linearly changing it starting from the previous event.
val exponential_ramp_to_value_at_time :
t ->
value:float ->
end_time:float ->
unit
exponential_ramp_to_value_at_time p ~value ~time
sets p
's value to value
at time end_time
by exponentially changing it starting from the previous event.
val set_target_at_time :
t ->
target:float ->
start_time:float ->
decay_rate:float ->
unit
set_target_at_time p ~value ~time ~decay_rate
transition p
's value towards value
at time time
.
val set_value_curve_at_time :
t ->
Brr.Tarray.float32 ->
start_time:float ->
dur_s:float ->
unit
set_value_curve_at_time p vs ~start_time ~dur_s
transitions p
's values through vs
during dur_s
seconds starting at time start_time
.