Skip to content

ISoundComponent

AutumnSky1010 edited this page Dec 10, 2022 · 2 revisions

Interface ISoundComponent

Definition

Namespace: SoundMaker.Sounds.Score
Assembly: SoundMaker.dll

Interface for sound components.

public interface ISoundComponent

Methods

GenerateWave(SoundFormat, int, int, WaveTypeBase)

Declaration

ushort[] GenerateWave(SoundFormat format, int tempo, int length, WaveTypeBase waveType);

Parameters

Type Desctiption
SoundFormat The format of the sound.
int Quarter note/rest per minute.
int Length of the array.
WaveTypeBase Type of wave.

Returns

Type Desctiption
ushort[] The array of wave data.

Exceptions

Exception Desctiption
ArgumentOutOfRangeException Tempo must be non-negative and greater than 0.
ArgumentOutOfRangeException Length must be non-negative.

GenerateWave(SoundFormat, int, WaveTypeBase)

Declaration

ushort[] GenerateWave(SoundFormat format, int tempo, WaveTypeBase waveType);

Parameters

Type Desctiption
SoundFormat The format of the sound.
int Quarter note/rest per minute.
WaveTypeBase Type of wave.

Returns

Type Desctiption
ushort[] The array of wave data.

Exceptions

Exception Desctiption
ArgumentOutOfRangeException Tempo must be non-negative and greater than 0.

GetWaveArrayLength(SoundFormat, int)

Declaration

int GetWaveArrayLength(SoundFormat format, int tempo)

Parameters

Type Desctiption
SoundFormat The format of the sound.
int Quarter note/rest per minute.

Returns

Type Desctiption
int Length of the sound array.

Exceptions

Exception Desctiption
ArgumentOutOfRangeException Tempo must be non-negative and greater than 0.
Clone this wiki locally