Announcement

Collapse
No announcement yet.

Changing the Default Sound Card

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Changing the Default Sound Card

    I have written a program which requires a "C-MEDIA WAVE DEVICE" sound card to enable it to transfer audio from a hard disk to a radio transmitter. However, when the transmitter is not being used I require to hear the audio in the computer headphones. To avoid plugging and unplugging cords I installed another sound card, a "REALTEK AC97 AUDIO" which works well just by altering which card is the default.
    I now wish to switch the cards automatically by placing code in my program so that when starting the program, it changes the default sound card to the C-Media one and reverts back to the Realtek 97 when I close the program down.
    Is there anyone who has done this or something similar who can help. I have searched the forums intensely without success. I am using PBWin 9.
    Denys C Brosnan

  • #2
    This might be a place to start:

    http://msdn.microsoft.com/en-us/library/ms790393.aspx

    Then do MSDN searches on various wavein and wave out functions.

    Cheers,
    Dale

    Comment


    • #3
      Thanks Dale. I looked it up ad found what I think I need in Win32Api.INC but unfortunately those functions are not covered by Win32.Hlp, well the copy I have any way so I have no way of knowing what the parameters are supposed to be. The MSDN data does not help in this respect either.
      I even tried to get a more uptodate version of Win32.Hlp but that appears as scarce as hens teeth to find.
      Any other ideas would be welcome.
      Denys
      Denys C Brosnan

      Comment


      • #4
        For a (almost) complete set of helpfiles, search for the 'B5MS.ZIP' file...
        Regards,
        Peter

        Comment


        • #5
          Thanks Peter. I tried the Borland site for B5MS.ZIP but could not figure out how to download it. But believe it or not I found Win32.Hlp on PB in a section I didn't know existed. Still did not have the info on "Waveinmessage" so am going back to MSDN
          Denys
          Denys C Brosnan

          Comment


          • #6
            I just downloaded the B5MS.ZIP from http://ftp.sun.ac.za/ftp/pub/mirrors...lder/techpubs/ to see if it was the same as the help files I downloaded years ago and it seems to be.

            When I opened WIN32SDK.HLP, clicked the Index tab and typed in "waveinmessage" it found an exact match and double clicking that match in the list box gave me a choice of two different locations for it. One of them is from the Multimedia Programmer's Reference.
            Jeff Blakeney

            Comment


            • #7
              Looks like you need the Microsoft Platform SDK CD (low cost) - order here: http://www.qmedia.ca/launch/psdk.htm

              Attached Files
              Rgds, Dave

              Comment


              • #8
                Maybe you don't NEED to "change the default sound card;" maybe what you need to do is learn, "How do I use a specific sound card when multiple cards are installed?"

                For which purpose...
                WaveGetNumDevices + waveOutGetDevCaps can tell you which device number you want to use... then you can play your wave data with WalveOutopen + WaveOutWrite.

                There's lots of other goodies (and probably some gotchas, too) in the SDK if you hunt around starting with these functions.

                I've never done this, but if I had to this is where I would start, especially since I am averse to making changes to a user's default system settings.

                MCM
                Michael Mattias
                Tal Systems Inc. (retired)
                Racine WI USA
                [email protected]
                http://www.talsystems.com

                Comment


                • #9
                  Dave. I tried the link you gave but could only get "PAGE CANNOT BE FOUND". Looks to me like it needs a LogOn filled in but I could not find that but thanks all the same. Will try and find another source of SDK.
                  Denys

                  Michael. That what I would like to do once I find SDK. There is one listed in 10 separate downloads from Microsoft but that is fo a server so am still looking. Thanks Denys


                  To All who answered my query.
                  I have found a SDK CD at Micro soft and ordered it (postage only). Will wait till I get it and then try again. Thanks to all for your help.
                  Denys
                  Last edited by Denys Brosnan; 9 Jun 2009, 10:17 PM.
                  Denys C Brosnan

                  Comment


                  • #10
                    I have found a SDK CD at Micro soft and ordered it (postage only). Will wait till I get it and then try again. Thanks to all for your help.
                    Do you still have the link where you could buy/download?

                    I tried a couple of years ago to buy but the site wouldn't accept non USA/Canada address.

                    Thanks, Bob
                    Last edited by Robert Wallace; 10 Jun 2009, 02:49 AM. Reason: Typo

                    Comment


                    • #11
                      Just tried this link again http://www.qmedia.ca/launch/psdk.htm

                      The links on QMedia's site are currently broken. (I've sent Q Media an email to ask what's up).

                      Meanwhile, here's another site that looks like a better option..

                      http://mssdk.orderport.net

                      (I previously ordered Microsoft Platform SDK for Windows XP SP2 August 2004 Edition - just going to get the Vista update DVD)
                      Last edited by Dave Biggs; 11 Jun 2009, 08:34 AM. Reason: Hmm QMedia's Page is OK but links are broken..
                      Rgds, Dave

                      Comment


                      • #12
                        Dave, all links are broken ...
                        "The trouble with quotes on the Internet is that you can never know if they are genuine." - Abraham Lincoln.

                        Comment


                        • #13
                          OK Here is another source that seems to be OK..

                          http://mssdk.orderport.net
                          Last edited by Dave Biggs; 11 Jun 2009, 08:38 AM.
                          Rgds, Dave

                          Comment


                          • #14
                            Until your CD arrives, all the SDK info is available on-line starting at http://msdn.microsoft.com/en-us/default.aspx

                            I would not try it without broadband as it's not terribly fast even with broadband; but the info is there. And once you get to the doc for any one of the listed functions, there are direct links to the related functions; MS did a pretty nice job of adding those links.

                            I go there now and then because my SDK-on-disk is from 2002 and there are sometimes corrections and additions to it in the on-line version.


                            MCM
                            Last edited by Michael Mattias; 10 Jun 2009, 08:12 AM.
                            Michael Mattias
                            Tal Systems Inc. (retired)
                            Racine WI USA
                            [email protected]
                            http://www.talsystems.com

                            Comment


                            • #15
                              OK Here is another source that seems to be OK..

                              http://mssdk.orderport.net/22221848/showall.asp
                              __________________
                              Rgds, Dave
                              Page not available from my part of the world today

                              Bob

                              Comment


                              • #16
                                Darn it ! Slippery sucker..

                                Try this http://mssdk.orderport.net
                                Rgds, Dave

                                Comment


                                • #17
                                  Gotcha!!!

                                  Many thanks, Bob

                                  Comment


                                  • #18
                                    Hi All. Seems I've stirred up a bit of a hornets nest.
                                    The address that I ordered from is:

                                    http://www.microsoft.com/downloads/d...displaylang=en

                                    Click on the word "order" and it will take you to a page showing a number of different DVD's with SDK on them. Select which one you require and you will be taken to the checkout. You will be required to register and select the method of delivery.
                                    The DVD is free but you pay for packing and shipping.
                                    Thanks to all for your help.
                                    Denys
                                    Denys C Brosnan

                                    Comment

                                    Working...
                                    X