Sha256: c741d40f012ef54f1698505cab2044529caabc4c3cb29df2e4f45324513b471a
Contents?: true
Size: 606 Bytes
Versions: 3
Compression:
Stored size: 606 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper') describe SPCore::DelayLine do it 'should' do SAMPLE_RATE = 44100.0 MAX_DELAY_SEC = 0.1 5.times do delay_line = SPCore::DelayLine.new( :sample_rate => SAMPLE_RATE, :max_delay_seconds => MAX_DELAY_SEC, :delay_seconds => (rand * MAX_DELAY_SEC) ) rand_sample = rand delay_line.push_sample rand_sample delay_line.delay_samples.times do delay_line.push_sample 0.0 end delay_line.delayed_sample.should eq(rand_sample) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
spcore-0.1.2 | spec/lib/delay_line_spec.rb |
spcore-0.1.1 | spec/lib/delay_line_spec.rb |
spcore-0.1.0 | spec/lib/delay_line_spec.rb |