This commit is contained in:
wangjiyu 2025-04-15 16:27:28 +08:00
parent dc9dd314d6
commit 35febd4b41
1 changed files with 2 additions and 2 deletions

View File

@ -115,7 +115,7 @@ void RTCContext::onAudioProcess(const char* roomId, const char* peerId,
Py_DECREF(repr); // 必须手动释放
}
PyGILState_STATE gstate = PyGILState_Ensure();
//PyGILState_STATE gstate = PyGILState_Ensure();
pyCallback_(
audioArray, // numpy 数组
data_size, // 数据大小
@ -124,7 +124,7 @@ void RTCContext::onAudioProcess(const char* roomId, const char* peerId,
audioFrame.numChannels,
audioFrame.channelIndex
);
PyGILState_Release(gstate);
//PyGILState_Release(gstate);
std::cout << " after callback" << std::endl;
if (PyErr_Occurred()) {
PyObject *type, *value, *traceback;