🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.multimedia
Article #867

Mixer problem

#867
From: George Nemeth
Date: Fri, 07 Mar 2003 15:20
31 lines
2198 bytes
I am having problems with the mixer devices under win98. The following 
code works fine with win95 and nt4, but the call to

auxGetNumDevs() returns 0 all the time when run under win98.  We tried several machines with the same result. Can anyone shed an light on why, OR suggest a different method of controlling the mixer.  We simply need to lower the line in audio level, play a wav and then restore the line in back to the level it was previously at. 

int TStation::GetLineInDevice()
{
  //return # that identifies line in dev in aux dev list
  AUXCAPS auxcaps;
  int nDevId;
  int nNbrAuxDevices = auxGetNumDevs();  //<--always returns zero under win98
  int rc;
  bool found = false;

  for(nDevId = 0; nDevId < nNbrAuxDevices; nDevId++) {
    rc = auxGetDevCaps(nDevId, &auxcaps, sizeof(auxcaps));
    if(rc == MMSYSERR_NOERROR &&
       (auxcaps.wTechnology & AUXCAPS_AUXIN) &&
       (auxcaps.dwSupport & AUXCAPS_VOLUME)) {
      ShowMessage("Got Aux In");
      found = true;
      break;
    }
  }

  if(found) {
    return nDevId;
  } else {
    return -1;
  }
}
Technical Details
Message-ID: <3e68b86c$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-03!sn-xit-06!sn-xit-08!supernews.com!38.144.126.75.MISMATCH!feed1.newsreader.com!newsreader.com!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10d0fc,40172c977b3a476a,start
X-Google-Attributes: gid10d0fc,public
X-Google-ArrivalTime: 2003-03-07 07:40:21 PST
Date: Fri, 07 Mar 2003 09:20:33 -0600
From: George Nemeth <gnemeth@globalkiosk.com>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.1) Gecko/20020826
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.multimedia
Subject: Mixer problem
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 24.72.2.113
Message-ID: <3e68b86c$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1047050348 24.72.2.113 (7 Mar 2003 07:19:08 -0800)
Lines: 32
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-03!sn-xit-06!sn-xit-08!supernews.com!38.144.126.75.MISMATCH!feed1.newsreader.com!newsreader.com!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail