debug
This commit is contained in:
parent
00672f25fe
commit
8eb7adb0fd
|
@ -101,16 +101,10 @@ void RTCContext::onAudioProcess(const char* roomId, const char* peerId,
|
|||
// 增加引用计数防止提前释放
|
||||
//Py_INCREF(pyCallback_.ptr());
|
||||
try {
|
||||
/*
|
||||
std::cout << " pyCallback_ type: " << Py_TYPE(pyCallback_.ptr())->tp_name << std::endl;
|
||||
PyObject* repr = PyObject_Repr(pyCallback_.ptr());
|
||||
if (repr) {
|
||||
std::cout << " pyCallback_ repr: " << PyUnicode_AsUTF8(repr) << std::endl;
|
||||
Py_DECREF(repr); // 必须手动释放
|
||||
}
|
||||
*/
|
||||
|
||||
//PyGILState_STATE gstate = PyGILState_Ensure();
|
||||
std::cout << "data:" << audioFrame.data << std::endl;
|
||||
std::cout << "当前线程是否持有 GIL: " << PyGILState_Check() << std::endl;
|
||||
np::ndarray audioArray = np::from_data(
|
||||
audioFrame.data, // 数据指针
|
||||
dtype, // 数据类型 (int16)
|
||||
|
|
Loading…
Reference in New Issue