Sound sample rate for window xp sp2
843802May 4 2010 — edited May 4 2010hello,
i have developed an audio recorder programme for recording sound in wave formate
with following Audio Formate
float sampleRate = 8000.0F;
int sampleSizeInBits = 16;
int channels = 1;
boolean signed = true;
boolean bigEndian = false;
return new AudioFormat(sampleRate,
sampleSizeInBits,
channels,
signed,
bigEndian);
above code return a audio formate object .
after recording i have megerd this file my .mov files by a merging programe .
this works fine when i execute this code on windows xp service pack-3
but
when i tried to run this code on xp-sp2 or on windows -7 it gives null pinter Exception in folling line
AudioSystem.getLine(dataLineInfo);
following error is occured related to audio formate
java.lang.IllegalArgumentException: No line matching interface TargetDataLine supporting format PCM_SIGNED 8000.0 Hz, 16 bit, mono, 4 bytes/frame, little-endian is supported.
at javax.sound.sampled.AudioSystem.getLine(Unknown Source)
now i think it is the problem related to audio formate supported by various version of xp...
can any one tell me what is the audio formate credentials for xp-sp2 and for windows -7
thanks
jitendra shrivatava