Hi,
I'm trying to record and measure how loud the volume is using J2ME/JSR-135.
p = Manager.createPlayer("capture://audio?encoding=pcm");
p.realize();
RecordControl rc = (RecordControl)p.getControl("RecordControl");
ByteArrayOutputStream output = new ByteArrayOutputStream();
rc.setRecordStream(output);
rc.startRecord();
p.start();
This works perfectly fine, I get audio into my output structure and can play it back perfectly fine, however, how can I measure how loud the volume is? Is there some class/method that can tell me the dB volume level of an arbitrary PCM stream of audio?
Does this exist in JSR-135 or as part of J2ME? Perhaps somewhere else?
If it doesn't exist, how should I go about writing something like this myself?
No replies to this topic
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account

Back to top









