0

I wish to do a program in c++ that enables me to play music as part of my school project.
I want to know if is this is possible.
I also wish to know if photos and other media can be similarly accessed and where i can get information on how to do the above.

4
Contributors
6
Replies
8
Views
7 Years
Discussion Span
Last Post by sachin.tendul
0

standalone i dont think c++ can play anythings other than pc-speaker sounds, so if you plan to play actual music (mp3 etc) you'd need to look into fmod, bass audio lib, alegro (or whatever they call it) and so on.

1

If you wish to play music there are 2 ways possible:
Windows PlaySound() : Works only for .wav
MMSYSTEM mciSendString(): Works for midi & mp3

Photo's can also be read just like normal file's & barring their header information I don't see what you can make of it, since you cannot display them like an Image Viewer inside your program until & unless it's an Windows form app.

0

windows form app? :s
What exactly does that mean?

And the what is the syntax for the above mentioned functions?
How should the file location be specified?

0

If you'd like to restrict yourself purely to windows here's a few things you can look into: Win32api, MFC (Microsoft Foundation Class), ATL(Active Template Library), WTL (Windows Template Library).

each and every one should give you access to image processing and some form of sound/music handling.

0

HI SHIJO
You can always do that. For that you need to installed latest windows SDK and you will find Microsoft DirectX - DirectShow library in the Multimedia folder. This library provides a set of C++ APIs to handle multimedia streams.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.