Class: FMOD::Effects::Delay
- Defined in:
- lib/fmod/effects/delay.rb
Overview
Every time MaxDelay is changed, the plugin re-allocates the delay buffer. This means the delay will disappear at that time while it refills its new buffer.
A larger #max_delay results in larger amounts of memory allocated.
Channel delays above #max_delay will be clipped to MaxDelay and the delay buffer will not be re-sized.
This unit produces different delays on individual channels of the sound.
Instance Attribute Summary collapse
-
#max_delay ⇒ Float
Maximum delay in ms.
Attributes inherited from Dsp
#active, #bypass, #channel_format, #input_count, #output_count, #parameter_count, #parent, #type, #wet_dry_mix
Attributes inherited from Handle
Instance Method Summary collapse
-
#[](channel) ⇒ Float
Retrieves the delay, in ms, for the specified channel.
-
#[]=(channel, delay) ⇒ Float
Sets the delay, in ms, for the specified channel.
Methods inherited from Dsp
#add_input, bool_param, data_param, #disconnect, #disconnect_from, #enable_metering, float_param, from_handle, #get_bool, #get_data, #get_float, #get_integer, #idle?, #info, #input, #input_connection, #input_metering?, integer_param, #name, #output, #output_connection, #output_format, #output_metering?, #param_info, #play, #reset, #set_bool, #set_data, #set_float, #set_integer, #set_wet_dry_mix, #show_dialog, #to_s, type_map, #version
Methods inherited from Handle
#initialize, #int_ptr, #release, #to_s
Constructor Details
This class inherits a constructor from FMOD::Handle
Instance Attribute Details
#max_delay ⇒ Float
Maximum delay in ms.
-
Minimum: 0.0
-
Maximum: 10000.0
-
Default: 10.0
21 22 23 |
# File 'lib/fmod/effects/delay.rb', line 21 def max_delay @max_delay end |
Instance Method Details
#[](channel) ⇒ Float
Retrieves the delay, in ms, for the specified channel.
27 28 29 |
# File 'lib/fmod/effects/delay.rb', line 27 def [](channel) get_float(channel.clamp(0, 15)) end |
#[]=(channel, delay) ⇒ Float
Sets the delay, in ms, for the specified channel.
36 37 38 39 |
# File 'lib/fmod/effects/delay.rb', line 36 def []=(channel, delay) set_float(channel.clamp(0, 15), delay.clamp(0.0, 10000.0)) delay end |