My application record sound from phone microphone. I am using android standard classes (android.media.AudioRecord) to do that. Appli
android.media.AudioRecord
when i replaced totalAbsValue += Math.abs( sample ) / (numberOfReadBytes/2) by totalAbsValue += (float)Math.abs( sample ) / ((float)numberOfReadBytes/(float)2) then it work fine.
totalAbsValue += Math.abs( sample ) / (numberOfReadBytes/2) by totalAbsValue += (float)Math.abs( sample ) / ((float)numberOfReadBytes/(float)2)