AudioConverter input/output buffer size and more...
AudioConverter input/output buffer size and more...
- Subject: AudioConverter input/output buffer size and more...
- From: Philippe Wicker <email@hidden>
- Date: Mon, 28 Jul 2003 23:36:13 +0200
Hello all,
Following the general trend, I am replacing my own conversion code with
code based on the use of the AudioConverter. I have obtained some
results which leave me perplex:
1. I couldn't convert an interleaved stereo signed 16 bits integer to
non interleaved stereo float32 using AudioConverterConvertBuffer (I
always receive an error 'insz' - invalid input size). If I change the
float32 to interleaved, then no more error. Is it really impossible to
convert interleaved -> non interleaved using
AudioConverterConvertBuffer?
2. When I call AudioConverterGetProperty with CalculateInputBufferSize,
a source format interleaved stereo signed 16 bits integer, a
destination format canonical (float32) 2 channels non interleaved, both
format with the same sample rate (44100.0), I obtain the same size for
input than for output. If the destination is interleaved, then I obtain
half the size on output. It looks like the returned size is the size of
the buffers for one channel. Is it right?
3. Under the same condition, if I change the sample rate of the source
format to 48000.0, then I obtain 1152 on input for an output size of
1024. This is about 37 more than what would have given the sample rate
ratio (48000/44100) * 1024. Why these extra samples? Trailing frames?
4. Any guidelines about trailing and leading frames values when using
PrimeMethod_pre or normal?
Thanks for any answer.
Philippe Wicker
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.