[android-developers] AudioRecord works with short but static with byte

2010-01-08 Thread Biosopher
Any idea why reading bytes from AudioRecord would cause an error while reading shorts would not? The sound comes through great with short but I get only static with bytes. Working code with short[]: int minBufferSize = AudioRecord.getMinBufferSize(this.getSampleRate(),

Re: [android-developers] AudioRecord works with short but static with byte

2010-01-08 Thread Jason Proctor
knee-jerk answer: because the individual samples are 16 bits wide, and by reading just a byte each time, you're only getting half the sample. Any idea why reading bytes from AudioRecord would cause an error while reading shorts would not? The sound comes through great with short but I get