C# 클래스 GSF.Media.Music.Song

Allows creation of a synthesized musical score storing the resultant song in an in-memory wave file for play back or saving music to disk.
상속: WaveFile
파일 보기 프로젝트 열기: GridProtectionAlliance/gsf

공개 메소드들

메소드 설명
AddNotes ( ) : void

Add a series of notes to the song.

AddPhrase ( GSF.Media.Music.Phrase phrase ) : void

Add a predefined phrase of notes to the song.

AddRest ( NoteValue restLength ) : void

Add a rest for the given length for the current beat.

AddRest ( NoteValue restLength, int dots ) : void

Add a rest for the given length for the current beat.

AddRest ( NoteValueBritish restLength ) : void

Add a rest for the given length for the current beat.

AddRest ( NoteValueBritish restLength, int dots ) : void

Add a rest for the given length for the current beat.

AddRest ( double restLength ) : void

Add a rest for the given length for the current beat.

Finish ( ) : void

Called when there are no more notes to add.

This flushes the remaining queued notes into the song allowing them to run their remaining time.

SetCrescendoDynamic ( int totalBeats, Dynamic endDynamic ) : void

Starts crescendo dynamic over the range of the specified number of beats.

Current Dynamic is the starting dynamic which should be less than endDynamic.

SetDiminuendoDynamic ( int totalBeats, Dynamic endDynamic ) : void

Starts diminuendo dynamic over the range of the specified number of beats.

Current Dynamic is the starting dynamic which should be greater than endDynamic.

Song ( ) : System

Creates a new song with a 3/4 measure size, a tempo of 240 quarter-notes per minute, mezzo-forte prevailing dynamic level, using a basic note timbre and standard CD-quality settings for the underlying sound file.

Song ( SampleRate sampleRate, BitsPerSample bitsPerSample, DataChannels channels ) : System

Creates a new song with a 3/4 measure size, a tempo of 240 quarter-notes per minute, mezzo-forte prevailing dynamic level, using a basic note timbre and the specified audio format settings.

비공개 메소드들

메소드 설명
AddQueuedNotesToSong ( long samplePeriod ) : void

메소드 상세

AddNotes() 공개 메소드

Add a series of notes to the song.
public AddNotes ( ) : void
리턴 void

AddPhrase() 공개 메소드

Add a predefined phrase of notes to the song.
public AddPhrase ( GSF.Media.Music.Phrase phrase ) : void
phrase GSF.Media.Music.Phrase Phrase to add.
리턴 void

AddRest() 공개 메소드

Add a rest for the given length for the current beat.
public AddRest ( NoteValue restLength ) : void
restLength NoteValue Duration of wait specified as a note value.
리턴 void

AddRest() 공개 메소드

Add a rest for the given length for the current beat.
public AddRest ( NoteValue restLength, int dots ) : void
restLength NoteValue Duration of wait specified as a note value.
dots int Total dotted note length extensions to apply.
리턴 void

AddRest() 공개 메소드

Add a rest for the given length for the current beat.
public AddRest ( NoteValueBritish restLength ) : void
restLength NoteValueBritish Duration of wait specified as a note value.
리턴 void

AddRest() 공개 메소드

Add a rest for the given length for the current beat.
public AddRest ( NoteValueBritish restLength, int dots ) : void
restLength NoteValueBritish Duration of wait specified as a note value.
dots int Total dotted note length extensions to apply.
리턴 void

AddRest() 공개 메소드

Add a rest for the given length for the current beat.
public AddRest ( double restLength ) : void
restLength double Duration of wait specified as a note value.
리턴 void

Finish() 공개 메소드

Called when there are no more notes to add.
This flushes the remaining queued notes into the song allowing them to run their remaining time.
public Finish ( ) : void
리턴 void

SetCrescendoDynamic() 공개 메소드

Starts crescendo dynamic over the range of the specified number of beats.
Current Dynamic is the starting dynamic which should be less than endDynamic.
public SetCrescendoDynamic ( int totalBeats, Dynamic endDynamic ) : void
totalBeats int Total number of beats overwhich to gradually increase volume.
endDynamic Dynamic Desired volume when crescendo is complete.
리턴 void

SetDiminuendoDynamic() 공개 메소드

Starts diminuendo dynamic over the range of the specified number of beats.
Current Dynamic is the starting dynamic which should be greater than endDynamic.
public SetDiminuendoDynamic ( int totalBeats, Dynamic endDynamic ) : void
totalBeats int Total number of beats overwhich to gradually decrease volume.
endDynamic Dynamic Desired volume when diminuendo is complete.
리턴 void

Song() 공개 메소드

Creates a new song with a 3/4 measure size, a tempo of 240 quarter-notes per minute, mezzo-forte prevailing dynamic level, using a basic note timbre and standard CD-quality settings for the underlying sound file.
public Song ( ) : System
리턴 System

Song() 공개 메소드

Creates a new song with a 3/4 measure size, a tempo of 240 quarter-notes per minute, mezzo-forte prevailing dynamic level, using a basic note timbre and the specified audio format settings.
public Song ( SampleRate sampleRate, BitsPerSample bitsPerSample, DataChannels channels ) : System
sampleRate SampleRate Desired sample rate
bitsPerSample BitsPerSample Desired bits-per-sample
channels DataChannels Desired data channels
리턴 System