Applet which stores 0.5 seconds of audio in an array
I'm new to Java programming, and I'm trying something a little complicated. I wish to use Java write an applet to listen to a microphone or line in port and wait for the input signal to reach positive saturation.
When the signal has saturated, I would then like to record the next 0.5 seconds of audio data samples into a numerical array.
Please may somebody explain how I can achieve this, if it is possible.
After that, I know what I want to do with the numerical array and how to do it.
I am using JDK 1.6.0_13
Thank you to everyone who can help.
There are a couple of things to know here.
1) The Java Sound API - This is how you get to capture or play sound using Java.
javax.sound.sampled is exactly what you require. The Guide here will help you get started with using sound within half an hour.
2) Security - By default, only signed applets can access sound APIs if I remember right. If you want an unsigned applet to capture sound, you should manually set the required permissions on the target JVM. See this for the permission to set, and this for more info on policy file(s).
By JavaEnthusiast in forum C++
Last Post: 04-10-2009, 02:16 AM
By Tmcclain in forum Java
Last Post: 02-13-2009, 10:57 PM
Last Post: 06-13-2008, 08:11 AM
Last Post: 08-17-2006, 03:59 PM
By Charlie Flynn in forum Java
Last Post: 08-23-2001, 11:01 AM
Tags for this Thread
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center