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

AudioConverter


  • Subject: AudioConverter
  • From: Martin Hairer <email@hidden>
  • Date: Mon, 18 Nov 2002 09:58:28 +0000

Hi,

I think a similar issue has already been raised on this list, but I couldn't find
it and I'm not sure it was really resolved.

The problem I am running into is that of changing the sampling rate of a piece
of sound using an AudioConverter. When I use AudioConverterConvertBuffer
with a comfortable value for ioOutputDataSize, I always get a
kAudioConverterErr_InvalidInputSize error, which probably means that the
AudioConverter would like to fill up my output buffer completely but doesn't have
enough data in the input buffer. Why doesn't it simply fill up as much as possible
and writes the achieved size in the ioOutputDataSize variable?

In other words, is there a simple way to tell an AudioConverter to convert some buffer
of input data into a (big) output buffer and to tell me how many bytes were actually
written to the output buffer? I must have overlooked something obvious, since this sounds
to me like one of the main uses for an AudioConverter...

I've already tried to call kAudioConverterPropertyCalculateOutputBufferSize prior
to AudioConverterConvertBuffer, but it doesn't work either, since it seems to always
return some minimal (or maximal) size for the buffer, but not the precise size...

Thanks for any insight,

Martin
_______________________________________________
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.

  • Follow-Ups:
    • Re: AudioConverter
      • From: Bill Stewart <email@hidden>
    • Re: AudioConverter
      • From: Doug Wyatt <email@hidden>
  • Prev by Date: Re: Carbon Support for SPBRecordToFile
  • Next by Date: Re: It had to be tried...
  • Previous by thread: Re: new to sound
  • Next by thread: Re: AudioConverter
  • Index(es):
    • Date
    • Thread