• 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
Re: kAudioFormatFlagIsFloat sample range
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: kAudioFormatFlagIsFloat sample range


  • Subject: Re: kAudioFormatFlagIsFloat sample range
  • From: "Stephen F. Booth" <email@hidden>
  • Date: Sun, 12 Sep 2010 17:01:15 -0700

On Sun, Sep 12, 2010 at 12:09 AM, Brian Willoughby <email@hidden> wrote:

On Sep 11, 2010, at 20:49, Stephen F. Booth wrote:
If kAudioFormatFlagIsFloat is set as part of an ExtAudioFile's client format, should the returned samples be in the range [-1, 1)? I've always worked under this assumption but I can't find anything explicit in the documentation.  I've recently observed samples being returned from AAC files with values >= 1 (and < -1), which is causing clipping on one of my devices. It isn't difficult to perform hard limiting, but this is something I hadn't noticed before.
I was under the impression that CoreAudio device drivers would always hard clip before sending data to the DAC.  Is that not happening in your case?  I guess hard clipping is not quite as gentle as hard limiting, though...

In my testing the Core Audio drivers do hard clip before data is sent if one is performing mixable IO.  In my particular case I am performing non-mixable IO in the device's native format (24 bit LE signed integer) so the drivers are passing my buffers to the DAC unmodified.  I didn't verify that the output from ExtAudioFileRead was in the correct range, so I was sending samples > 0x7fffff to the device. Some devices handle this with no audible artifacts, but some don't.  For now as a temporary solution I am just clipping the ExtAudioFile return data using vDSP_vclip which solves the problem.

Stephen
 _______________________________________________
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

References: 
 >kAudioFormatFlagIsFloat sample range (From: "Stephen F. Booth" <email@hidden>)
 >Re: kAudioFormatFlagIsFloat sample range (From: Brian Willoughby <email@hidden>)

  • Prev by Date: Re: kAudioFormatFlagIsFloat sample range
  • Next by Date: kAudioSessionProperty_ServerDied
  • Previous by thread: Re: kAudioFormatFlagIsFloat sample range
  • Next by thread: Bump; help request - core audio and iOS4
  • Index(es):
    • Date
    • Thread