Background Tunes ?

Started by
5 comments, last by gxe 22 years ago
I''m relatively inexperienced in DirectX development - I have recently completed the on-line tutorial and now have a working Tetris-clone game. I''m now in the process of ''tarting it up'' and would like to improve the graphics and sound. Graphics are no problem (if time consuming !), but with the sound, I''ve hit a brick wall. The existing code has a simple "Play" using a .wav sample and gets played each time a level is completed, but what I really want is an authentic ''annoying background tune'' ! i.e. Get a sample file (.wav or other format ?) and simply play it over and over again during game play until it is specifically stopped (e.g. at Game Over). Ideally, I''d actually like to do something better, such as speed up the tempo as the game speeds up, but that''s probably something for a later date. So far, I haven''t managed to find anywhere that simply shows the commands used to a) initiate the DirectSound buffers, load the sample file, etc b) start playing the tune in a loop; and c) stop playing the tune. ******************** If anyone could provide this, or a suitable link I would very much appreciate it. ******************** - or should I take the lack of simple information on the subject to imply that it''s all far more complex than this ? If this is the case then could anyone provide any pointers on where to start ? ******************** Cheers !
Cheers !eddSoftwww.eddsoft.com
Advertisement
Check out the DirectX Audio docs and sample applications. They''re not too hard to follow, and can show how audio is loaded and played.

What kind of sound are you after? I''d recomment a midi for background music, as waves can get big, and mp3 is slightly beyond this level.

- Pete
If your interested in playing MP3''s this link might help
http://www.fairyengine.com/articles/playmp3.htm
SiasPete & the anonymous poster, thanks for the responses.
I guess midi or mp3 would be a good bet, so I''ll check out your recommendations.

I''m actually a resonably proficient musician with good knowledge of music theory etc.
Does anyone know if there are there any good and easy-to-use freeware music composers which generate, say, midi files; or any good purchased programs that are worth the investment - I''d love to get into composing music again.

As always, thanks in advance.

Cheers !



Cheers !eddSoftwww.eddsoft.com
I started writing music back in the days of Scream Tracker (and Impulse Tracker and whatnot). Since upgrading my music-writing capability to Cakewalk and a nice, shiny keyboard, I''ve found that writing music to MIDI (or as I do, write it in semi-midi but output it to MP3 since my keyboard has a buttload of non-standard instruments that I use) is a heck of alot harder (to me) than tracking was.

So you may want to check out some trackers.

MAZ''s page ( http://www.maz-sound.com/ ) has some good software that you can use to track, and even some instrument packs to work with. You can then use something like WinAMP or maybe the tracker itself to convert the tracked songs into WAV or MP3, then use an audio program to equalize, reverb, whatever the final result.


Just a suggestion, obviously this idea doesn''t really help on the MIDI front. But I just thought I''d put it out on the table
Ah I remember Amiga trackers, I loved OctaMED when I was younger. A few trackers will provide a library to play back modules you create with them, so you don''t have to write the code from scratch.


How To Ask Questions The Smart Way
There is a nice DirectMusic article here complete with code you can take, and basically use in your program.

-=Lohrno

This topic is closed to new replies.

Advertisement