Hello! Thank you very much for this project!
Please help me to understand how I can retrieve the Frame Width, Frame Height and Frame Type (I or P frame). My code example is based on testRTSPClient.cpp I am in the function DummySink::afterGettingFrame fSubsession.videoWidth() and fSubsession.videoHeight() always return 0. All other parameters works fine. I have h264 video. Please help! Thank you! void DummySink::afterGettingFrame(unsigned frameSize, unsigned numTruncatedBytes, struct timeval presentationTime, unsigned /*durationInMicroseconds*/) { if (mAudioVideoIn != NULL) { mAudioVideoIn->OnFrameReceived(fStreamId, fSubsession.mediumName(), fSubsession.codecName(), fReceiveBuffer, frameSize, fSubsession.videoWidth(), fSubsession.videoHeight(), 0); } // We've just received a frame of data. (Optionally) print out information about it: #ifdef DEBUG_PRINT_EACH_RECEIVED_FRAME if (fStreamId != NULL) envir() << "Stream \"" << fStreamId << "\"; "; envir() << fSubsession.mediumName() << "/" << fSubsession.codecName() << ":\tReceived " << frameSize << " bytes"; if (numTruncatedBytes > 0) envir() << " (with " << numTruncatedBytes << " bytes truncated)"; char uSecsStr[6 + 1]; // used to output the 'microseconds' part of the presentation time sprintf(uSecsStr, "%06u", (unsigned)presentationTime.tv_usec); envir() << ".\tPresentation time: " << (int)presentationTime.tv_sec << "." << uSecsStr; if (fSubsession.rtpSource() != NULL && !fSubsession.rtpSource()->hasBeenSynchronizedUsingRTCP()) { envir() << "!"; // mark the debugging output to indicate that this presentation time is not RTCP-synchronized } #ifdef DEBUG_PRINT_NPT envir() << "\tNPT: " << fSubsession.getNormalPlayTime(presentationTime); #endif envir() << "\n"; #endif // Then continue, to request the next frame of data: continuePlaying(); }
_______________________________________________ live-devel mailing list live-devel@lists.live555.com http://lists.live555.com/mailman/listinfo/live-devel