Subject: Re: [ecasound] Metronome problems (l-ecasound: addressed to trusted sender for this address)
From: Stefan Bund (l-ecasound.d.xalan_AT_xoxy.net)
Date: Tue Nov 04 2003 - 10:04:52 EET
Kai Vehmanen <k_AT_eca.cx> writes:
> Actually I'll have to take my previous statement. Ecasound's
> metronome (-pn:metronome) does _not_ use sin(). Rather the sine wave
> is generated by 'sine_fcac' LADSPA plugin which comes with the
> LADSPA SDK. 'sine_fcac' generates a precomputed sin-table, so it's
> pretty fast.
I just found out the same by looking at the source.
> I guess the efficiency problem comes from the use of the preset
> system. The metronome is defined as:
> metronome = -el:sine_fcac,880,1 -eemb:%1,10 -efl:2000 \
> -ppn:bpm -ppd:100 -pd:Sineosc_metronome
Hmm. Why do you have a Low-pass filter in there??? I mean, a *sine*
wave does not have harmonics... it's just one frequency so there is
nothing to be filtered...
> There are plenty of example code out there if someone is interested:
> - LADSPA SDK: src/plugins/sine.cpp
> - table-basd sine-wave generation
I looked at that. I have been thinking of converting it to a wave-table
based metronome with a 'real' metronome click
> - ecasound: libecasound/audiofx_envelope_modulation.cpp
> - signal gate that opens X times per second
> - JACK: examples/metro.c
> - a complete metronome implemented as a JACK client app
> - btw; you can use this as is with ecasound
Thats interesting. I've never used JACK. Is this worth the trouble?
Does JACK introduce additional overhead/latency?
> - ardour: ardour/libs/ardour/default_click.cc
> - wavetable-based metronome-click generation
> - ardour: ardour/libs/ardour/session_click.cc
> - how the session click is generated
> .. you just have to put the piece together. :)
Maybe I will, if I find the time. If I try to do it, would it be
OK to implement an LADSPA-Plugin or should I go the direct ecasound
route in terms of efficiently?
> If you want to take a quick'n'dirty approach, try adding the following to
> your ~/.ecasound/effect_presets:
> metronome_light = -el:sine_fcac,880,1 -eemb:%1,10 \
> -ppn:bpm -ppd:100 -pd:Sineosc_metronome_light
I'll certainly try that.
Thanks you for the detailed informations,
This archive was generated by hypermail 2b28 : Tue Nov 04 2003 - 10:20:28 EET