| | |
How do you include sound files in C++?
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
I'll check around, i know someone who did it recently. You may also want to check the following to see if they help you: http://www.codeguru.com/Cpp/G-M/mult...cle.php/c4739/
There is a playsound() function that will may sound files....but i think it has a limit of 100kb.
There is a playsound() function that will may sound files....but i think it has a limit of 100kb.
Well, I've heared about it, try this code! but it think it works on
old compiler such as Turbo C++ V3.
[code=c++]
#include <stdio.h>
#include <conio.h>
#include <stdlib.h>
#include <dos.h>
int main()
{
clrscr();
sound(100);
delay(100); //or you can use pause
nosound(); // for stopping sound
return 0;
}
old compiler such as Turbo C++ V3.
[code=c++]
#include <stdio.h>
#include <conio.h>
#include <stdlib.h>
#include <dos.h>
int main()
{
clrscr();
sound(100);
delay(100); //or you can use pause
nosound(); // for stopping sound
return 0;
}
Farzad Zafarani
Well, I've heard about it, try this code! but it think it works on
old compiler such as Turbo C++ V3.
old compiler such as Turbo C++ V3.
c++ Syntax (Toggle Plain Text)
#include <stdio.h> #include <conio.h> #include <stdlib.h> #include <dos.h> int main() { clrscr(); sound(100); delay(100); //or you can use pause nosound(); // for stopping sound return 0; }
Farzad Zafarani
![]() |
Similar Threads
- sound of a water drip (Windows NT / 2000 / XP)
- #include custom files (C++)
- How To Load Sound Files In C++ (C++)
- Sound Troubles (Windows 95 / 98 / Me)
- sound file switching (C)
- Please~~~ Need help including sound files in the form! (C#)
- Problems with Windows Script Encoder & #include directive (ASP)
- no sound when playing mp3 or wma files (Windows NT / 2000 / XP)
- Can you add pictures/sounds in a win32 console app? (C)
Other Threads in the C++ Forum
- Previous Thread: Sum of Series help
- Next Thread: Confusing Problem
| Thread Tools | Search this Thread |
api array arrays based binary c++ c/c++ calculator char char* class classes code coding compile console conversion convert count database delete deploy desktop developer directshow dll download dynamic dynamiccharacterarray email encryption error file forms fstream function functions game generator givemetehcodez google graph gui homeworkhelp iamthwee ifstream input int java lib linkedlist linker list loop looping loops map math matrix memory multiple news number numbertoword output pointer problem program programming project python random read recursion recursive reference return rpg sorting string strings temperature template templates test text text-file tree unix url variable vector video visual visualstudio win32 windows winsock wordfrequency wxwidgets







id really appreciate it thx