• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
USB Mic Volume in 10.2.8
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

USB Mic Volume in 10.2.8


  • Subject: USB Mic Volume in 10.2.8
  • From: Doug Zwick <email@hidden>
  • Date: Tue, 22 May 2007 12:11:34 -0600

I have some code that records audio data from a mic using Core Audio (it is part of an internet conferencing application). It includes a volume control, attached to a "recording level" slider in the application's GUI. I am using AudioDeviceSetProperty on kAudioDevicePropertyVolumeScalar to set the volume level it is recording at. This works fine for every mic we've been able to find under OS X 10.3.9 and 10.4.9. Unfortunately, under 10.2.8 some devices return kAudioHardwareUnknownPropertyError. In looking through the archives of this list, it seems to be a FAQ why this doesn't work for every device, and the answer is because the device does not have a volume control. I ran Audio MIDI Setup and verified that the devices in question (all are USB headsets) do not show a volume control under 10.2.8, but do show one under 10.3.9. I am curious about the difference in behaviour between 10.2.8 and 10.3.9/10.4.8 -- was Core Audio enhanced to simulate a master volume control for such devices? Is my only option for adjusting the volume of the audio data in this situation to track the volume level myself, and multiply each sample by some fraction (e.g. by 0.7)? I know that the desired multiplier value is not in a linear relationship with the volume slider position, so I shouldn't just multiply by the kAudioDevicePropertyVolumeScalar property value -- what is a good function to obtain a multiplier from the scalar value (e.g. sqrt(v), log(v), etc.)?

Or is there a better way of implementing a "recording level" control?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: USB Mic Volume in 10.2.8
      • From: Jeff Moore <email@hidden>
  • Prev by Date: Re: ExtAudioFile questions
  • Next by Date: Re: ExtAudioFile questions
  • Previous by thread: Re: ExtAudioFile questions
  • Next by thread: Re: USB Mic Volume in 10.2.8
  • Index(es):
    • Date
    • Thread