AXART_LFO

C Specification

#include <revolution.h>
#include <revolution/axart.h>
typedef struct
{
f32         *lfo;           // lfo samples in RAM
u32         length;         // lfo samples for 1 period
f32         delta;          // lfo delta per 5ms
    
u32         sampleIndex;    // lfo sample index
f32         counter;        // lfo counter
f32         sample1;        // lfo last sample for interpolation
f32         sample;         // lfo sample
f32         output;         // lfo output

} AXART_LFO;

Description

AXART_LFO is a data structure for an LFO. AXART_LFO is used by articulators that modulate volume or pitch. To apply an articulator containing an LFO to an AXART_SOUND, the AXART_LFO must be initialized by calling AXARTInitLfo() prior to calling AXARTAddArticulator().

Data Member Description
f32 *lfo Pointer to the first sample of LFO shape in RAM. This parameter is maintained by AXART. Do not write to this parameter.
u32 length Number of samples for the LFO. This parameter is maintained by AXART. Do not write to this parameter.
f32 delta Sample index delta per audio frame. This sets period frequency for the LFO.
delta =  Hz * (length / 200).
The user may change this at any time.
u32 sampleIndex Current sample index for LFO output. This parameter is maintained by AXART. Do not write to this parameter.
f32 counter Running counter for output sample interpolation. Interpolation is linear. This parameter is maintained by AXART. Do not write to this parameter.
f32 sample1 Last LFO sample for interpolation. This parameter is maintained by AXART. Do not write to this parameter.
f32 sample Current LFO sample for interpolation. This parameter is maintained by AXART. Do not write to this parameter.
f32 output Output for LFO. This parameter is maintained by AXART. Do not write to this parameter.

See Also

AXARTInitLfo
AXARTAddArticulator
AXART_SOUND

Revision History

03/01/2006 Initial version.