fixed #192
This commit is contained in:
1 parent
d9b94f83fe
commit
7f0330856d
20 files changed
+1159
-52
No files matched your search
@@ -104,12 +104,12 @@ namespace HandyControlDemo.ViewModel
|
||||
|
||||
private void StartRecord()
|
||||
{
|
||||
ExternDllHelper.MciSendString("set wave bitpersample 8", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("set wave samplespersec 20000", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("set wave channels 2", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("set wave format tag pcm", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("open new type WAVEAudio alias movie", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("record movie", "", 0, 0);
|
||||
Win32Helper.MciSendString("set wave bitpersample 8", "", 0, 0);
|
||||
Win32Helper.MciSendString("set wave samplespersec 20000", "", 0, 0);
|
||||
Win32Helper.MciSendString("set wave channels 2", "", 0, 0);
|
||||
Win32Helper.MciSendString("set wave format tag pcm", "", 0, 0);
|
||||
Win32Helper.MciSendString("open new type WAVEAudio alias movie", "", 0, 0);
|
||||
Win32Helper.MciSendString("record movie", "", 0, 0);
|
||||
|
||||
_stopwatch.Reset();
|
||||
_stopwatch.Start();
|
||||
@@ -135,9 +135,9 @@ namespace HandyControlDemo.ViewModel
|
||||
|
||||
var cachePath = $"{AudioCachePath}\\{Guid.NewGuid().ToString()}";
|
||||
var cachePathWithQuotes = $"\"{cachePath}\"";
|
||||
ExternDllHelper.MciSendString("stop movie", "", 0, 0);
|
||||
ExternDllHelper.MciSendString($"save movie {cachePathWithQuotes}", "", 0, 0);
|
||||
ExternDllHelper.MciSendString("close movie", "", 0, 0);
|
||||
Win32Helper.MciSendString("stop movie", "", 0, 0);
|
||||
Win32Helper.MciSendString($"save movie {cachePathWithQuotes}", "", 0, 0);
|
||||
Win32Helper.MciSendString("close movie", "", 0, 0);
|
||||
|
||||
_stopwatch.Stop();
|
||||
|
||||
|
||||
Reference in new issue
Block a user