Play sound in TurboC++

This is a discussion on Play sound in TurboC++ within the C++ Programming forums, part of the General Programming Boards category; Hello can any body say the code needed to play sound Iam Using Turbo C++ 3.0 and Windows XP I ...

  1. #1
    Registered User
    Join Date
    Nov 2006
    Posts
    9

    Play sound in TurboC++

    Hello
    can any body say the code needed to play sound
    Iam Using Turbo C++ 3.0 and Windows XP
    I could not find a better match in this forum(as i have searched the forum)
    please can any body say the code

    even the Beep() function is not working (may be i don't internal speakers)

    and I don't have windows.h to include to be able to use PlaySound()

  2. #2
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Portugal
    Posts
    7,383
    char doBeep = '\a';

    std::cout << doBeep;
    The programmer’s wife tells him: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.”
    The programmer comes home with 12 loaves of bread.


    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  3. #3
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,341
    As opposed to the better idea of getting a more up to date compiler suited to your OS, and using one of several win32 APIs available.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  4. #4
    Its hard... But im here swgh's Avatar
    Join Date
    Apr 2005
    Location
    England
    Posts
    1,475
    Like salem said, you need the platform SDK to use windows.h header. Turbo C++ is pretty acient. Three good "free" IDE/compilers are DevC++ - free from bloodshed's website

    code::blocks IDE and Microsoft Visual 2005 Express edition - although if you go with express you need to speratley download the SDK from the website, links can be found in the help files
    I'm just trying to be a better person - My Name Is Earl

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. DirectX Question
    By bladerunner627 in forum Game Programming
    Replies: 2
    Last Post: 04-04-2005, 11:55 AM
  2. Low latency sound effects
    By VirtualAce in forum Game Programming
    Replies: 0
    Last Post: 12-21-2004, 12:58 AM
  3. Updated sound engine code
    By VirtualAce in forum Game Programming
    Replies: 8
    Last Post: 11-18-2004, 11:38 AM
  4. Gui Class With Tic Tac Toe
    By xxYukoxx in forum C++ Programming
    Replies: 1
    Last Post: 06-01-2003, 04:28 PM
  5. sounds?
    By BODYBUILDNERD in forum C++ Programming
    Replies: 6
    Last Post: 12-06-2002, 02:34 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21