Re: [Super-tux-devel] stereo sound patch
Brought to you by:
wkendrick
From: Ingo R. <gr...@gm...> - 2003-12-28 19:38:33
|
Duong-Khang NGUYEN <neo...@us...> writes: > 2. Adds: Stereo sound effects. In "gameloop.c" the kicked laptop now produces > stereo sound depending on the position of SuperTux I don't think that the position of Tux itself should be used for calculating the sound position, but instead the center of the screen/camera. After all the view of the player and Tux are not really the same, even so there are pretty close most of the time. > 3. Changes: "play_sound( Mix_Chunk * snd)" > now is "play_sound( Mix_Chunk * snd, enum Sound_Speaker whichSpeaker )" > where whichSpeaker is > SOUND_CENTER_SPEAKER, > SOUND_LEFT_SPEAKER, > SOUND_RIGHT_SPEAKER Why limit the sound to just three enums? Wouldn't it be better to have a play_sound(Mix_Chunk* snd, float pos) and thus allow sound to be positioned exactly, instead of being one speaker or the other (center will never be reached, since tux_x won't be equal to bad_guy_x in practice)? -- WWW: http://pingus.seul.org/~grumbel/ JabberID: gr...@ja... ICQ: 59461927 |