Skip to content
Browse files

Clarifying the number of channels needed and why.

  • Loading branch information...
1 parent efd3de3 commit b7fa6f4cba48792595495a7b58ca7dee9fa87610 @kthakore kthakore committed Dec 24, 2010
Showing with 2 additions and 2 deletions.
  1. +1 −1 code_listings/sound_event.pl
  2. +1 −1 src/08-music_and_sound.pod
View
2 code_listings/sound_event.pl
@@ -20,7 +20,7 @@
);
# Initialize the Audio
-unless ( SDL::Mixer::open_audio( 44100, AUDIO_S16SYS, 2, 4096 ) == 0 ) {
+unless ( SDL::Mixer::open_audio( 44100, AUDIO_S16SYS, 1, 4096 ) == 0 ) {
Carp::croak "Cannot open audio: " . SDL::get_error();
}
View
2 src/08-music_and_sound.pod
@@ -29,7 +29,7 @@ C<open_audio> will open an audio device with frequency at 44100 Mhz, audio forma
Next we will load sound samples that generally used for sound effects and the like. Currently C<SDL_Mixer> reserves samples for C<.WAV>, C<.AIFF>, C<.RIFF> C<.OGG>, and C<.VOC> formats.
-Samples run on one of the 2 channels that we opened up, while our background music will run on the other channels. To load samples we will be doing the following:
+Samples run on one of the 2 channels that we opened up, while the other channel will be reserved for multiple plays of the sample. To load samples we will be doing the following:
+use SDL::Mixer::Samples;

0 comments on commit b7fa6f4

Please sign in to comment.
Something went wrong with that request. Please try again.