Re: playout garbled in iPhone 3.x Release build (solved)
Re: playout garbled in iPhone 3.x Release build (solved)
- Subject: Re: playout garbled in iPhone 3.x Release build (solved)
- From: Tim <email@hidden>
- Date: Sun, 02 May 2010 13:45:30 -0700
Solved this problem, not what I expected at all. In my audio codec,
there is some bit testing code that looks like this:
long bits;
bits += bits; // shift bits left by 1
if( bits >= 0 ) {
// high order bit is 0
}
In the 3.x Release build, the test on bits >= 0 is never true, even if
printf("%d") prints it as positive. If I replace bits += bits with:
bits <<= 1;
then it works fine. Also, the bits += bits; works fine in Debug build
or with 2.2 target.
This is a bug right? Or, am I getting too old to write code?
Tim
I am trying to play 16-bit mono 8 khz PCM audio. Using either
AudioQueue or RemoteIO AudioUnit, I get following results:
Simulator - 2.2 | Release - correct
Device - 2.2 | Distribution -correct
Simulator - 3.1.2 | Debug - correct
Simulator - 3.1.2 | Release - garbled
Device - 3.1.2 | Distribution - garbled
Essentially, 2.2 build works everywhere. 3.1.2 build works only in
Simulator Debug (have not tested Device Debug). Any idea what to look
for here? The garbling sounds the same with either AudioQueue or
AudioUnit and on Device or Simulator. Hard to describe. It is not
choppy like frames being dropped, nor is it hissy like white noise.
Thanks for any ideas.
Tim
_______________________________________________
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