NPLRuntime
NPLRuntime copied to clipboard
录音支持
希望NPLRuntime可以有调用系统默认录音设备录制声音的支持。 录制的声音可以输出到文件。
what is the audio format? and we can only provide win32 solution for the moment
@SleepingBuffer we can add an recording API in MovieCodec plugin. And give an API to record microphone only.
format can be any type that nplruntime's audio engine can play.
got it
这个进展到哪一步了?
it will be done today
Please let us know when u commit this API, we'll merge it immediately into our branch. @SleepingBuffer
// start recording
ParaEngine::CAudioEngine2::GetInstance()->getMCIController()->Start();
// stop recording when you finish
ParaEngine::CAudioEngine2::GetInstance()->getMCIController()->Stop();
// save to the file
ParaEngine::CAudioEngine2::GetInstance()->getMCIController()->Save("C:/Users/azoth/Desktop/test.wav");
@e-setup
called from lua script
ParaAudio.StartRecording();
ParaAudio.StopRecording();
ParaAudio.SaveRecording("C:/Users/azoth/Desktop/test.wav");
@SleepingBuffer 调用录音接口录制的声音用NPLRumtime的播放接口播放不出来。 test.zip
Note: the audio file format must be native .wav