/* append tap to list in delay line */ public static void AppendTapToDelayEffect( DelayEffectRec DelaySpec, DelayTapRec Tap) { Array.Resize(ref DelaySpec.List, DelaySpec.List.Length + 1); DelaySpec.List[DelaySpec.List.Length - 1] = Tap; }
/* add a delay effect to the spec list */ public static void AddDelayToEffectSpecList( EffectSpecListRec EffectSpecList, DelayEffectRec DelaySpec, bool EnabledFlag) { AddGenericToEffectSpecList(EffectSpecList, EffectTypes.eDelayEffect, DelaySpec, EnabledFlag); }
/* create a new delay line specification */ public static DelayEffectRec NewDelayLineSpec() { DelayEffectRec DelaySpec = new DelayEffectRec(); DelaySpec.List = new DelayTapRec[0]; //DelaySpec.MaxDelayTime = 0; return(DelaySpec); }
public static void GetDelayTapFilterCutoffAgg( DelayEffectRec DelaySpec, int Index, out ScalarParamEvalRec ParamsOut) { DelayTapRec Tap = DelaySpec.List[Index]; InitScalarParamEval( Tap.FilterCutoff, ref Tap.FilterCutoffAccent, Tap.FilterCutoffFormula, out ParamsOut); }
public static void GetDelayTapScaleAgg( DelayEffectRec DelaySpec, int Index, out ScalarParamEvalRec ParamsOut) { DelayTapRec Tap = DelaySpec.List[Index]; InitScalarParamEval( Tap.ScaleFactor, ref Tap.ScaleFactorAccent, Tap.ScaleFactorFormula, out ParamsOut); }
public static void GetDelayTapTargetTimeAgg( DelayEffectRec DelaySpec, int Index, out ScalarParamEvalRec ParamsOut) { DelayTapRec Tap = DelaySpec.List[Index]; InitScalarParamEval( Tap.TargetTime, ref Tap.TargetTimeAccent, Tap.TargetTimeFormula, out ParamsOut); }
public static PcodeRec GetDelayMaxTimeFormula(DelayEffectRec DelaySpec) { return(DelaySpec.MaxDelayTimeFormula); }
public static bool GetDelayTapInterpolateFlag( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).Interpolate); }
public static LFOListSpecRec GetDelayTapCutoffLFO( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).CutoffLFO); }
public static LFOListSpecRec GetDelayTapScaleLFO( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).ScaleFactorLFO); }
public static LFOListSpecRec GetDelayTapTargetLFO( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).TargetTimeLFO); }
public static EnvelopeRec GetDelayTapCutoffEnvelope( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).CutoffEnvelope); }
public static EnvelopeRec GetDelayTapScaleEnvelope( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).ScaleFactorEnvelope); }
public static EnvelopeRec GetDelayTapTargetEnvelope( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).TargetTimeEnvelope); }
public static double GetDelayMaxTime(DelayEffectRec DelaySpec) { return(DelaySpec.MaxDelayTime); }
public static void SetDelayMaxTimeFormula( DelayEffectRec DelaySpec, PcodeRec MaxTimeFormula) { DelaySpec.MaxDelayTimeFormula = MaxTimeFormula; }
public static void SetDelayMaxTime( DelayEffectRec DelaySpec, double MaxTime) { DelaySpec.MaxDelayTime = MaxTime; }
public static DelayChannelType GetDelayTapTarget( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).TargetTap); }
public static DelayChannelType GetDelayTapSource( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).SourceTap); }
/* get a specified tap from the delay line */ public static DelayTapRec GetTapFromDelayEffectSpec( DelayEffectRec DelaySpec, int Index) { return(DelaySpec.List[Index]); }
/* get the number of taps in the delay line */ public static int GetDelayEffectSpecNumTaps(DelayEffectRec DelaySpec) { return(DelaySpec.List.Length); }
public static bool GetDelayTapFilterEnable( DelayEffectRec DelaySpec, int Index) { return(GetTapFromDelayEffectSpec(DelaySpec, Index).FilterEnable); }
/* check delay effect */ public static SynthErrorCodes CheckDelayEffectForUnreferencedSamples( DelayEffectRec DelayEffect, CheckUnrefParamRec Param) { int Limit = GetDelayEffectSpecNumTaps(DelayEffect); for (int Scan = 0; Scan < Limit; Scan += 1) { SynthErrorCodes Error; Error = CheckEnvelopeForUnreferencedSamples( GetDelayTapSourceEnvelope(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckEnvelopeForUnreferencedSamples( GetDelayTapTargetEnvelope(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckEnvelopeForUnreferencedSamples( GetDelayTapScaleEnvelope(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckEnvelopeForUnreferencedSamples( GetDelayTapCutoffEnvelope(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckLFOListForUnreferencedSamples( GetDelayTapSourceLFO(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckLFOListForUnreferencedSamples( GetDelayTapTargetLFO(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckLFOListForUnreferencedSamples( GetDelayTapScaleLFO(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } Error = CheckLFOListForUnreferencedSamples( GetDelayTapCutoffLFO(DelayEffect, Scan), Param); if (Error != SynthErrorCodes.eSynthDone) { return(Error); } } return(SynthErrorCodes.eSynthDone); }