Jump to content
  • Advertisement
Sign in to follow this  
Chetanhl

Best method for playing audio in directx?

This topic is 3046 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Whats difference between DirectSound, XACT and XAudio2 ? Which is best suited for games ? (Please post link to good tutorials of prefered one)

Share this post


Link to post
Share on other sites
Advertisement
I searched in DirectXSDK and found that DirectSound is Deprecated.
Found some tutorials of XACT and XAudio2 but they work with some .xsb file format.
Basically what am trying to do is to play .WAV files (for sound effects)
and .MP3 files (for background music or maybe .ogg).

So wanted to know whats the main purpose of XACT and XAudio2 and which will be best suited in my case ?
With some links or refrence to tutorials.

[Edited by - Chetanhl on February 19, 2010 5:22:40 AM]

Share this post


Link to post
Share on other sites
XAudio2 can play natively Wav, xWM, and almost anything your Windows Media Player can play right when installed.
The problem is that you HAVE to do parse of the format by yourself and give the raw data to XAudio2.

Share this post


Link to post
Share on other sites
Hi!

I want to load MP3s or OGGs into XAudio, and you sad, that I have to do the Parsing by myself.

How?

Share this post


Link to post
Share on other sites
Quote:
Original post by WuTz
Hi!

I want to load MP3s or OGGs into XAudio, and you sad, that I have to do the Parsing by myself.

How?
For OGG, there's libvorbis (Which is really nice and easy to use). For MP3s, you'll need to use an MP3 decoding library, or DirectShow, FMOD, etc.

Share this post


Link to post
Share on other sites
Hey what are the pro's and con's of using MCI in game for playing wav ,mp3 and even videos ??
Its relatively very easy to play multimedia files using MCI but i dunno if its good to use it in games ?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!