• Advertisement
  • entries
    338
  • comments
    2046
  • views
    1157671

In-game music / internet radio

Sign in to follow this  

262 views

Recently I've been struggling to decide how to do the in-game music. It would cost me a rediculous amount of money to have the kind of "soundtrack" I want for the game [ie: unique music for each gang type, and a fair amount of it]. I've decided to use internet radio stations as my source of music.

Today I got my license for the FMOD sound library [ http://www.fmod.org ] this is the 3rd sound library I have implemented into the game. I had DirectSound implemented before moving to OpenAL. OpenAL is alright but it's really not as "polished" and feature-full as I prefer lib to be [though the price was right ;-)]. FMOD is packed to the hilt with features so I'm glad to be making the switch, it looks to be a very interesting library.

The game engine's interfacing with the sound library is totally obfuscated, so it's relativly trivial for me to swap out sound libs. Though I'm going to spend some time on this one learning the ins and outs of the library and taking full advantage of it [ I'm really interested in the "geometry api" where you can feed your game world's geometry into the sound lib which would be ideal for buildings ].

Anyways, the main reason I went with FMOD was it's native support of shoutcast/icecast/http streaming radio. The client will pull down the list of radio stations from my webserver when the user starts the game. I'm not going to have a full shoutcast station browser / etc...though that would be cool I havn't the slightest idea where to start to implement it.

I'm going to support 12 stations each with different types of music.

Here is my work-in-progress of the in-game radio player...


The large section in the middle will be where the radio stations will be, the top part will scroll the current playing song, and the area in the middle of the two is for visualization of the current waveform [assuming FMOD provides a way for me to get this data, I havn't checked yet].

Each radio station type has it's own logo...


Let me know if I left out a genre...I can always add more stations.

The user will 'roll' through these based on the mouses' position...I'm not going to have a scroll bar. This should create a nice smooth effect.

Ok well now that this artwork stuff is done I'm going to implement FMOD into the engine and get these radio stations working in the game. Should have some nice progress tommorow.

Also, it looks like I'm getting close to joining the "100k journal views" club. Awesome, I appreciate the readership.

- Dan
Sign in to follow this  


6 Comments


Recommended Comments

Don't forget the "User Radio Station" so we can hear our own music while playing the game.

I liked the way GTA:SA handled it. Basically, one could create shortcuts in a special folder to the places where one has stored some music files in the MP3, OGG or WAV format. Then, GTA:SA would scan the referenced folders and play the music files when the "User Radio Station" was chosen.

Share this comment


Link to comment
Reggae and Talk Radio would be cool (those were always my fav stations in GTA3 along with the 80s music [wink])

Share this comment


Link to comment
Gaheris - Well adding native .mp3 support into the game has some other implications, one I have to pay an extra $2.5k for a .mp3 license...which isn't really a big deal, but for small % of people who will actually take the time to setup shortcuts etc it seems like a waste.

I would be happy adding .mp3 support if I had a integrated in-game folder browser to select the music folders...but I really dont feel like coding one of those up.

The GTA route you mention is a way around that. So they just had a folder called "User Radio" and you add shortcuts into that folder that point elsewhere on your computer...how do you setup the shortcuts? In the standard way...ie: right click create shortcut an d drag it into the folder? That seems rather inconvinient to the user. I should just go buy GTA:SA its like 20 bucks now.

The way I was doing it before would have required the user to drag / drop their .mp3 files into the game's Music directory.

ViLiO - Good ideas, I'll add a comedy / talk / reggae station later today.

mrlachatte - Yup old school radio dial sounds for transisition between stations, cant go wrong with those >:D

- Dan

Share this comment


Link to comment
Yeah, I knew that when I mentioned adding MP3 support that it would probably mean that you'd have to pay lots of bucks for that. The thing is that a User Radio Station without MP3 support is most likely not usable for most people.

The folder is called "C:\Documents and Settings\[UserName]\My Documents\GTA San Andreas User Files\User Tracks" and yes, these are the normal windows shortcuts you can create by drag and drop or by opening the context menu and selecting New->Shortcut. In the audio settings menu ingame one can choose to let GTA:SA either scan those folders on startup every time (which slows down starting the game a bit) or one can do the scanning manually.

Share this comment


Link to comment
As long as you've got the "Vinnie Baggadonuts" gangster guy in the game, I'll be chillin' to the Jazz station. =b Oh, and you'll need some Old School, Big Band, Frank Sinatra type stuff in there too. "You talkin' to me? You?! Talkin' to ME?!" [grin]

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Advertisement