Solved

using sound in c++

Posted on 1997-08-06
3
576 Views
Last Modified: 2012-06-27
I am just getting started in c++. I have read several books on the subject and have compiled some small programs. With Borland C++ 5.02. I want to use sounds (ie. play .wav files for certain events) in my programs. How do I get started with this? Is there a reference that talks about this. The ones I have read say nothing about sound. They deal only in graphics and text displays.
0
Comment
Question by:ko542
3 Comments
 
LVL 1

Accepted Solution

by:
mosfet earned 100 total points
ID: 1166936
You should get the book "Tricks of the Game Programming Gurus". Not only is it a good book for programming games, but it also has information on how to use sounds. Here is a list of all the books that talk about sound:

Tricks of the Game Programming Gurus
Black Art of 3D Game Programming
More Tricks of the Game Programming Gurus

0
 
LVL 23

Expert Comment

by:chensu
ID: 1166937
See Win32 SDK documentation about Waveform Audio under Multimedia section.

The simplest method is using the PlaySound function. There are also other methods: MCI commands, low-level waveform audio functions and DirectSound.
0
 

Author Comment

by:ko542
ID: 1166938
Could you elaborate on chensu's comment or maybe he could. Where can I find more info on these MCI commands,low-level waveform audio functions and DirectSound?
           thanks
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question