Open GoogleCodeExporter opened 8 years ago
Try to copy the byte audioData [] into a new byte [] using
System.arrayCopy(..). Here's a snippet of code I found in
http://www.java-tips.org/other-api-tips/jogl/line-antialiasing-timing-ortho-view
-and-simple-sounds-nehe-tutorial-jogl.html
private static byte[] trim(byte[] data, int amount) {
if (data == null) {
return new byte[amount];
} else if (data.length == amount) {
return data;
} else {
byte[] newArray = new byte[amount];
System.arraycopy(data, 0, newArray, 0, amount);
return newArray;
}
}
Original comment by seahlin...@gmail.com
on 9 Oct 2010 at 3:50
ok, i will go through the java code in the URL link.Thanks anyway !!
Original comment by sywong10...@gmail.com
on 9 Oct 2010 at 6:01
Original issue reported on code.google.com by
sywong10...@gmail.com
on 4 Oct 2010 at 4:24