• 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: How to capture audio generated by a render callback, iOS
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to capture audio generated by a render callback, iOS


  • Subject: Re: How to capture audio generated by a render callback, iOS
  • From: Tim Kemp <email@hidden>
  • Date: Thu, 06 Dec 2012 08:17:09 -0500

They are identical, Joel:

// Set output format (RemoteIO)
        memset(&_outputASBD, 0, sizeof(_outputASBD));
        _outputASBD.mSampleRate        = 44100.0;
        _outputASBD.mFormatID          = kAudioFormatLinearPCM;
        _outputASBD.mFormatFlags       = kAudioFormatFlagIsSignedInteger | kAudioFormatFlagIsBigEndian | kAudioFormatFlagIsPacked;
        _outputASBD.mBytesPerPacket    = 2 * 2;
        _outputASBD.mBytesPerFrame     = 2 * 2;
        _outputASBD.mFramesPerPacket   = 1;
        _outputASBD.mChannelsPerFrame  = 2;
        _outputASBD.mBitsPerChannel    = 16;

        

        // Set recording format (ExtAudioFileWriteAsync)
        memset(&_fileASBD, 0, sizeof(_fileASBD));
        _fileASBD.mSampleRate          = 44100.00;
        _fileASBD.mFormatID            = kAudioFormatLinearPCM;
        _fileASBD.mFormatFlags         = kAudioFormatFlagIsSignedInteger | kAudioFormatFlagIsBigEndian | kAudioFormatFlagIsPacked;;
        _fileASBD.mBytesPerPacket      = 2 * 2;
        _fileASBD.mBytesPerFrame       = 2 * 2;
        _fileASBD.mFramesPerPacket     = 1;
        _fileASBD.mChannelsPerFrame    = 2;
        _fileASBD.mBitsPerChannel      = 16;

        

I just tried now changing both ASBDs to 32 bits per channel, 8 bytes per packet and frame. I left everything else. Audio from the speakers was fine as usual, but this time both recorded channels were pure noise.



On 6 Dec 2012, at 07:58, Joel Reymont wrote:

Your ASBD has to match the audio you are receiving from the AU.

If you are receiving 32-bit audio then your ASBD bits per channel
should be 32, no?

On Thu, Dec 6, 2012 at 12:41 PM, Tim Kemp <email@hidden> wrote:

       _fileASBD.mBitsPerChannel      = 16;

--------------------------------------------------------------------------
for hire: mac osx device driver ninja. kernel, usb and coreaudio drivers
---------------------+------------+---------------------------------------
http://wagerlabs.com | @wagerlabs | http://www.linkedin.com/in/joelreymont
---------------------+------------+---------------------------------------

 _______________________________________________
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: How to capture audio generated by a render callback, iOS
      • From: Joel Reymont <email@hidden>
References: 
 >How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Gregory Wieber <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Aran Mulholland <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Joel Reymont <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Paul Davis <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Joel Reymont <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Tim Kemp <email@hidden>)
 >Re: How to capture audio generated by a render callback, iOS (From: Joel Reymont <email@hidden>)

  • Prev by Date: Re: How to capture audio generated by a render callback, iOS
  • Next by Date: Re: How to capture audio generated by a render callback, iOS
  • Previous by thread: Re: How to capture audio generated by a render callback, iOS
  • Next by thread: Re: How to capture audio generated by a render callback, iOS
  • Index(es):
    • Date
    • Thread