查bug时看了部分代码,整理了一下调用关系。
供自己以后查询,其他人估计没有参考价值。。
===> 前后调用关系
liveMedia/MultiFramedRTPSink.cpp:
149 Boolean MultiFramedRTPSink::continuePlaying() and
412 void MultiFramedRTPSink::sendNext(void* firstArg) ===>
165 void MultiFramedRTPSink::buildAndSendPacket(Boolean isFirstPacket) ===>
194 void MultiFramedRTPSink::packFrame() ===>
215 fSource->getNextFrame(fOutBuf->curPtr(), fOutBuf->totalBytesAvailable(),
216 afterGettingFrame, this, ourHandleClosure, this); ===>
liveMedia/FramedSource.cpp :
57 void FramedSource::getNextFrame(unsigned char* to, unsigned maxSize,
58 afterGettingFunc* afterGettingFunc,
59 void* afterGettingClientData,
60 onCloseFunc* onCloseFunc,
61 void* onCloseClientData) ===>
liveMedia/FramedSource.cpp :
78 doGetNextFrame(); ===>
XXX_FramedSource.cpp
nextTask() = envir().taskScheduler().scheduleDelayedTask(0,
(TaskFunc*)FramedSource::afterGetting, this);
liveMedia/FramedSource.cpp :
81 void FramedSource::afterGetting(FramedSource* source) ===>
liveMedia/MultiFramedRTPSink.cpp:
void MultiFramedRTPSink
221 ::afterGettingFrame(void* clientData, unsigned numBytesRead,
222 unsigned numTruncatedBytes,
223 struct timeval presentationTime,
224 unsigned durationInMicroseconds) ===>
liveMedia/MultiFramedRTPSink.cpp:
230 void MultiFramedRTPSink
231 ::afterGettingFrame1(unsigned frameSize, unsigned numTruncatedBytes,
232 struct timeval presentationTime,
233 unsigned durationInMicroseconds) ===> (also call packFrame())
liveMedia/MultiFramedRTPSink.cpp:
357 void MultiFramedRTPSink::sendPacketIfNecessary() ===>
nextTask() = envir().taskScheduler().scheduleDelayedTask(uSecondsToGo, (TaskFunc*) sendNext, this);