我正在使用Sphinx的hello world jar文件&包括Sphinx4.jar& WSJ _..._ 6800Hz.jar ......
代码如下所示:
object App {
def main(args: Array[String]): Unit = {
edu.cmu.sphinx.demo.helloworld.HelloWorld.main(Array[String]())
}
}
但我收到错误:
SEVERE: couldn't find suitable target audio format
[error] (run-main-1) java.lang.IllegalArgumentException: No line matching interface TargetDataLine is supported.
java.lang.IllegalArgumentException: No line matching interface TargetDataLine is supported.
at javax.sound.sampled.AudioSystem.getLine(AudioSystem.java:479)
at edu.cmu.sphinx.frontend.util.Microphone.getAudioLine(Microphone.java:330)
at edu.cmu.sphinx.frontend.util.Microphone.open(Microphone.java:359)
at edu.cmu.sphinx.frontend.util.Microphone.startRecording(Microphone.java:435)
at edu.cmu.sphinx.demo.helloworld.HelloWorld.main(HelloWorld.java:41)
at example.App$.main(App.scala:10)
at example.App.main(App.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
[trace] Stack trace suppressed: run last compile:run for the full output.
java.lang.RuntimeException: Nonzero exit code: 1
at scala.sys.package$.error(package.scala:27)
[trace] Stack trace suppressed: run last compile:run for the full output.
[error] (compile:run) Nonzero exit code: 1
[error] Total time: 6 s, completed Aug 29, 2014 11:06:43 PM
5. Waiting for source changes... (press enter to interrupt)
我在这里做错了什么?