• 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: AudioConverter error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AudioConverter error


  • Subject: Re: AudioConverter error
  • From: Bill Stewart <email@hidden>
  • Date: Fri, 7 Mar 2003 10:36:36 -0800

ConvertBuffer is only useful for doing straight conversions (not for sample rates or other more intricate conversions) - we should and will at some point return an error...

In the SDK there is some Play Audio file code (in the PublicUtility directory, as well as example code that uses it) that does exactly what you want and you can just take that code and either use it directly or use it for help

Bill

On Thursday, March 6, 2003, at 07:43 PM, Sailor Quasar wrote:

I'm using two connected V2 AudioUnits, a default output unit and a stereo mixer. My input source is an AudioFile. I'm trying to use an AudioConverter to convert the file data (interleaved 44KHz 16-bit 2-channel signed integer linear PCM) to the default input format of the stereo mixer (non-interleaved 44KHz 32-bit 2-channel floating-point linear PCM). I've managed to figure out how to stop a crash by actually allocating the right buffer size, but AudioConverter is giving me back 'insz', kAudioConverterErr_InvalidInputSize. The comment in the header says:
// e.g. byte size is not a multiple of the frame size
This makes no sense to me; my input buffer size is set as mBytesPerFrame * framesRequested. My AudioStreamBasicDescription (both the one for the file and the one for the default mixer input) is the same one passed to AudioConverterNew(). Also, this only happens the first time through my render proc; the second time through, I get an access fault exception inside AudioConverterConvertBuffer(). Can anyone help me?

-- Sailor Quasar, High Codemaster of the Web, scourge of systems
cvs server: Updating Quasar/brain/caffiene
A pepsi
R coke
Email: email@hidden
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.


-- mailto:email@hidden
tel: +1 408 974 4056

________________________________________________________________________ __
"Much human ingenuity has gone into finding the ultimate Before.
The current state of knowledge can be summarized thus:
In the beginning, there was nothing, which exploded" - Terry Pratchett
________________________________________________________________________ __
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.
References: 
 >AudioConverter error (From: Sailor Quasar <email@hidden>)

  • Prev by Date: Re: Audio Units vs Audio HAL? (newbie question)
  • Next by Date: Mixer units
  • Previous by thread: AudioConverter error
  • Next by thread: AudioConverter question
  • Index(es):
    • Date
    • Thread