Mixing Music and Sfx
Posted: Sat Nov 15, 2014 2:51 pm
Hi,
i'm new on the Genesis Homebrew Scene, and i'm trying do to a port of Pang for the megadrive.
Here is a video of a Work In Progress : https://www.youtube.com/watch?v=2Jod7r1F6K8
90% of the game logic is coded (even it's not show in the video), but i would make some music and sfx for the game.
I've succeeded playing music, converting midi to vgm and using :
SND_startPlay_VGM(pang13OK);
The music is ok (even if the midi is ugly, it's the same ugly music on the Genesis ).
I've trying to play a sample (.wav) alone :
SND_startPlay_PCM ( ball_explode, 2304,SOUND_RATE_11025,SOUND_PAN_CENTER,0) ;
It's ok too.
When i try to mix the two :
SND_startPlay_VGM(pang13OK);
and
SND_playSfx_VGM (ball_explode, 2304);
It works, but the .wav, the ball explosion is not good, it looks like the sample has eaten a cat ...
I use rescomp and this configuration for the wav file :
# Generated with rescomp
VGM pang13OK "pang13OK.vgm"
WAV ball_explode "ball_explode.wav" 0 11025
Surely i'm doing something wrong, but how i can mix music and sfx with sgdk ?
Thanks a lot.
i'm new on the Genesis Homebrew Scene, and i'm trying do to a port of Pang for the megadrive.
Here is a video of a Work In Progress : https://www.youtube.com/watch?v=2Jod7r1F6K8
90% of the game logic is coded (even it's not show in the video), but i would make some music and sfx for the game.
I've succeeded playing music, converting midi to vgm and using :
SND_startPlay_VGM(pang13OK);
The music is ok (even if the midi is ugly, it's the same ugly music on the Genesis ).
I've trying to play a sample (.wav) alone :
SND_startPlay_PCM ( ball_explode, 2304,SOUND_RATE_11025,SOUND_PAN_CENTER,0) ;
It's ok too.
When i try to mix the two :
SND_startPlay_VGM(pang13OK);
and
SND_playSfx_VGM (ball_explode, 2304);
It works, but the .wav, the ball explosion is not good, it looks like the sample has eaten a cat ...
I use rescomp and this configuration for the wav file :
# Generated with rescomp
VGM pang13OK "pang13OK.vgm"
WAV ball_explode "ball_explode.wav" 0 11025
Surely i'm doing something wrong, but how i can mix music and sfx with sgdk ?
Thanks a lot.