macos 10.15.7
使用的cpp接口,TXLiteAVSDK_TRTC_Mac版本8.2.9808
如果在调用sendCustomVideoData后释放内存就会崩溃,不释放就会内存泄漏(从资源管理器可以看到内存占用在持续升高)
TRTCVideoFrame frame;
frame.videoFormat = TRTCVideoPixelFormat_I420;
frame.bufferType = TRTCVideoBufferType_Buffer;
frame.width = 1280;
frame.height = 720;
frame.length = (1280*720*3)/2;
frame.rotation = TRTCVideoRotation0;
frame.data = (char*)malloc(frame.length);
memset(frame.data,0,frame.length);
frame.timestamp = 0;
mEngine->sendCustomVideoData(&frame);
free(frame.data);
相似问题