Changed naming convention for local variables

git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/branches/sfml2@1181 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
LaurentGom 2009-07-17 08:11:03 +00:00
parent 34817446c0
commit 16275d05e8
5 changed files with 174 additions and 174 deletions

View file

@ -26,24 +26,24 @@ namespace sample_sound
private static void PlaySound()
{
// Load a sound buffer from a wav file
SoundBuffer Buffer = new SoundBuffer("datas/sound/footsteps.wav");
SoundBuffer buffer = new SoundBuffer("datas/sound/footsteps.wav");
// Display sound informations
Console.WriteLine("footsteps.wav :");
Console.WriteLine(" " + Buffer.Duration + " sec");
Console.WriteLine(" " + Buffer.SampleRate + " samples / sec");
Console.WriteLine(" " + Buffer.ChannelsCount + " channels");
Console.WriteLine(" " + buffer.Duration + " sec");
Console.WriteLine(" " + buffer.SampleRate + " samples / sec");
Console.WriteLine(" " + buffer.ChannelsCount + " channels");
// Create a sound instance and play it
Sound Sound = new Sound(Buffer);
Sound.Play();
Sound sound = new Sound(buffer);
sound.Play();
// Loop while the sound is playing
while (Sound.Status == SoundStatus.Playing)
while (sound.Status == SoundStatus.Playing)
{
// Display the playing position
Console.CursorLeft = 0;
Console.Write("Playing... " + Sound.PlayingOffset + " sec ");
Console.Write("Playing... " + sound.PlayingOffset + " sec ");
// Leave some CPU time for other processes
Thread.Sleep(100);
@ -56,23 +56,23 @@ namespace sample_sound
private static void PlayMusic()
{
// Load an ogg music file
Music Music = new Music("datas/sound/lepidoptera.ogg");
Music music = new Music("datas/sound/lepidoptera.ogg");
// Display music informations
Console.WriteLine("lepidoptera.ogg :");
Console.WriteLine(" " + Music.Duration + " sec");
Console.WriteLine(" " + Music.SampleRate + " samples / sec");
Console.WriteLine(" " + Music.ChannelsCount + " channels");
Console.WriteLine(" " + music.Duration + " sec");
Console.WriteLine(" " + music.SampleRate + " samples / sec");
Console.WriteLine(" " + music.ChannelsCount + " channels");
// Play it
Music.Play();
music.Play();
// Loop while the music is playing
while (Music.Status == SoundStatus.Playing)
while (music.Status == SoundStatus.Playing)
{
// Display the playing position
Console.CursorLeft = 0;
Console.Write("Playing... " + Music.PlayingOffset + " sec ");
Console.Write("Playing... " + music.PlayingOffset + " sec ");
// Leave some CPU time for other processes
Thread.Sleep(100);