Posted By:
khalid_hayat
Posted On:
Wednesday, August 7, 2002 02:21 PM
Hi Benny
Plz try down the following stepss to perform the capture audio from microphone and stored to file.
1-
Find out the microphone CaptureDeviceInfo through
DataSource ds;
Vector audioDeviceList=new Vector();
CaptureDeviceInfo aCDI=null;
audioDeviceList=CaptureDeviceManager.getDeviceList(new AudioFormat("linear",44100,16,2));
aCDI=(CaptureDeviceInfo)audioDeviceList.firstElement();
System.out.println("aCDI : " + aCDI.getName());
ds=Manager.createDataSource(aCDI.getLocator());
2- Then create a processor from datasource and
then set the specific contenetType and set format of audio track as u wish.
3-Then passed this processor output to datasink object
and call open(),start() on datassink.
I think this step will solve your problem