gpt4 book ai didi

audio - Livecode错误-231开始录制

转载 作者:行者123 更新时间:2023-12-02 22:32:34 24 4
gpt4 key购买 nike

我正在尝试为正在创建的实验记录音频文件。这是我正在使用的代码:

global gSubjectID
global recordcount
on mouseUp
set the recordFormat to "wave" -- or "wave" or "ulaw"
set the recordCompression to "raw "
set the itemDelimiter to "/"
get the effective fileName of this stack
set the defaultFolder to item 1 to -2 of it
if not (the hilite of me) then

if recordcount is 1 then
put gSubjectID & space & "Question 1.wav" into fld "recordFileName"
put fld "recordFileName" into sndName

# make sure there's a name
if sndName is empty then
exit mouseUp
end if

set the hilite of me to true
record sound file sndName
add 1 to recordcount
end if
end if
end mouseUp

一切似乎正常,当我使用其他按钮停止录音时,麦克风打开,然后关闭。

我添加了代码
put the result

为了弄清楚为什么它不起作用,我得到了这个错误:

error -231 starting recording



LiveCode论坛上尚未解决此问题,所以我想在这里尝试。

笔记:
Quicktime 7.7.7 / Livecode版本7.01 / Windows 10

最佳答案

录音功能使用QuickTime。从LiveCode 6.7开始,默认情况下不会加载QuickTime。您必须告诉LC使用QT。尝试在record sound file命令之前的某处添加此行:

set the dontUseQT to false

关于audio - Livecode错误-231开始录制,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38108058/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com