Copyright © 2005-2019 MultiMedia Soft

Effects.DirectXEffectParamsSet method (Chorus)

Return to chapter overview

Remarks

 

Sets parameters related to the Chorus effect. The current parameters for the chosen effect can be retrieved using the Effects.DirectXEffectParamsGet method.

 

DirectX effects requires the availability of DirectX version 8 or higher on the target system and can be applied only if the IsDirectX8Available method returns TRUE.

 

See the How to apply special effects to a playing sound section for further details.

 

 

Syntax

 

[Visual Basic]

Public Function DirectXEffectParamsSet (

nPlayerIndex as Int16,

ByRef fx as Microsoft.DirectX.DirectSound.EffectsChorus

) as enumErrorCodes


 

[C#]

public enumErrorCodes DirectXEffectParamsSet (

Int16 nPlayerIndex,

ref Microsoft.DirectX.DirectSound.EffectsChorus fx

);


 

[C++]

public: enumErrorCodes DirectXEffectParamsSet (

Int16 nPlayerIndex,

Microsoft::DirectX::DirectSound::EffectsChorus __gc *fx

);


 

 

Parameter

Description

 

 

nPlayerIndex

Number representing the zero-based index of the involved player

fx

Reference to the effect structure containing parameters to apply.

Property

Meaning

 

 

Delay

Retrieves and sets the number of milliseconds the input is delayed before it is played back.

Can range from ChorusEffect.DelayMin to ChorusEffect.DelayMax.

The default value is 16 ms.

Depth

Retrieves and sets the percentage by which the delay time is modulated by the low-frequency oscillator, in hundredths of a percentage point.

Can range from ChorusEffect.DepthMin to ChorusEffect.DepthMax.

The default value is 10.

Feedback

Retrieves and sets the percentage of output signal to feed back into the effect's input.

Can range from ChorusEffect.FeedbackMin to ChorusEffect.FeedbackMax.

The default value is 25.

Frequency

Retrieves and sets the frequency of the LFO

Can range from ChorusEffect.FrequencyMin to ChorusEffect.FrequencyMax.

The default value is 1.1.

Phase

Retrieves and sets the phase differential between left and right LFOs

Can range from ChorusEffect.PhaseMin to ChorusEffect.PhaseMax.

Can be set by the one values below:

- ChorusEffect.PhaseZero

- ChorusEffect.Phase90

- ChorusEffect.PhaseNegative90

- ChorusEffect.Phase180

- ChorusEffect.PhaseNegative180

The default value is ChorusEffect.Phase90.

Waveform

Retrieves and sets the waveform shape of the LFO

Can be set by the one values below:

- ChorusEffect.WaveSin

- ChorusEffect.WaveTrianlge

The default value is ChorusEffect.WaveSin.

WetDryMix

Retrieves and sets the ratio of wet (processed) signal to dry (unprocessed) signal

Can range from ChorusEffect.WetDryMixMin to ChorusEffect.WetDryMixMax.

The default value is 50.

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred (see the LastError property for further error details)

Note that if you should fill the fx structure with values out of range, you could get an exception of type ArgumentException

enumErrorCodes.NOERROR (0)

The method call was successful.