2,543
社区成员
发帖
与我相关
我的任务
分享
m_hWnd = hWnd;
RTPSessionParams sessParams;
double frameRate = 1.0/30.0;
sessParams.SetOwnTimestampUnit(frameRate); //30 video frames per second
sessParams.SetUsePollThread(1); //background thread to call virtual callbacks - set by default, but just to be sure
sessParams.SetMaximumPacketSize(MAX_PACKET_SIZE+12);
RTPUDPv4TransmissionParams transParams;
transParams.SetPortbase(port);
int status = Create(sessParams, &transParams);
if(status < 0)
{
//std::cerr << RTPGetErrorString(status) << std::endl;
string str = RTPGetErrorString(status);
//return str;
}
SetDefaultPayloadType(96);
SetDefaultMark(false);
SetDefaultTimestampIncrement(10);
RTPTime delay(0.020);