C# Класс LitDev.LDMusic

Показать файл Открыть проект

Открытые методы

Метод Описание
EndNote ( Primitive value ) : void

Stop a note being played.

InstrumentName ( Primitive instrument ) : Primitive

Get an instrument name from its number.

PlayMusic ( Primitive notes ) : void

Plays musical notes.

PlayMusic2 ( Primitive notes, Primitive instrument, Primitive velocity, Primitive volume, Primitive pan, Primitive channel ) : void

Plays musical notes with specified instrument and MDI channel. Also set volume, pan (balance) and velocity (key hit speed).

PlayNote ( Primitive octave, Primitive note, Primitive channel ) : Primitive

Play an individual note (allows multi-channel instruments).

Reset ( ) : void

Reset (stop all music on all channels).

Приватные методы

Метод Описание
ChangeInstrument ( int number, int channel ) : void
ChangePan ( int number, int channel ) : void
ChangeVolume ( int number, int channel ) : void
EnsureDeviceInit ( ) : void
PlayNote ( int number, int channel ) : void
PlayNote ( int octave, string note, int length, int channel ) : void
PlayNotes ( string song, int channel ) : void
ResetDefaults ( ) : void
ResetDevice ( ) : void
StopNote ( int number, int channel ) : void
midiOutClose ( IntPtr midiOutt ) : int
midiOutOpen ( IntPtr &midiOut, uint uDeviceID, IntPtr dwCallback, IntPtr dwCallbackInstance, uint dwFlags ) : int
midiOutReset ( IntPtr midiOutt ) : int
midiOutSetVolume ( IntPtr midiOut, uint dwVolume ) : int
midiOutShortMsg ( IntPtr midiOut, uint dwMsg ) : int

Описание методов

EndNote() публичный статический Метод

Stop a note being played.
public static EndNote ( Primitive value ) : void
value Primitive The note to stop (this is the value returned by PlayNote when the note was started).
Результат void

InstrumentName() публичный статический Метод

Get an instrument name from its number.
public static InstrumentName ( Primitive instrument ) : Primitive
instrument Primitive The instrument number.
Результат Primitive

PlayMusic() публичный статический Метод

Plays musical notes.
public static PlayMusic ( Primitive notes ) : void
notes Primitive /// A set of musical notes to play. The format is a subset of the Music Markup Language supported by QBasic. ///
Результат void

PlayMusic2() публичный статический Метод

Plays musical notes with specified instrument and MDI channel. Also set volume, pan (balance) and velocity (key hit speed).
public static PlayMusic2 ( Primitive notes, Primitive instrument, Primitive velocity, Primitive volume, Primitive pan, Primitive channel ) : void
notes Primitive /// A set of musical notes to play. The format is a subset of the Music Markup Language supported by QBasic. ///
instrument Primitive The instrument number.
velocity Primitive The key velocity (1 to 128, default 100).
volume Primitive Volume (0 to 100, default 50).
pan Primitive Pan left (-100) or right (100) (default 0).
channel Primitive The MIDI channel (1 to 16).
Результат void

PlayNote() публичный статический Метод

Play an individual note (allows multi-channel instruments).
public static PlayNote ( Primitive octave, Primitive note, Primitive channel ) : Primitive
octave Primitive The octave (0 to 8).
note Primitive The note ("A","F#","B-" etc).
channel Primitive The MIDI channel (1 to 16).
Результат Primitive

Reset() публичный статический Метод

Reset (stop all music on all channels).
public static Reset ( ) : void
Результат void