Route CodecSpecificInfo from encoder to packetizer
Making a long chain of interface changes to route a CodecSpecificInfo struct from the video encoder function to the RTPSenderVideo. This will be used to convey information needed by the RTP packetizer when building the RTP headers. Review URL: http://webrtc-codereview.appspot.com/56001 git-svn-id: http://webrtc.googlecode.com/svn/trunk@140 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -1076,7 +1076,8 @@ ModuleRtpRtcpImpl::SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_UWord32 timeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation)
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr)
|
||||
{
|
||||
WEBRTC_TRACE(kTraceStream, kTraceRtpRtcp, _id,
|
||||
"SendOutgoingData(frameType:%d payloadType:%d timeStamp:%u payloadSize:%u)",
|
||||
@ -1095,11 +1096,13 @@ ModuleRtpRtcpImpl::SendOutgoingData(const FrameType frameType,
|
||||
if(!haveChildModules)
|
||||
{
|
||||
retVal = _rtpSender.SendOutgoingData(frameType,
|
||||
payloadType,
|
||||
payloadType,
|
||||
timeStamp,
|
||||
payloadData,
|
||||
payloadSize,
|
||||
fragmentation);
|
||||
fragmentation,
|
||||
NULL,
|
||||
rtpTypeHdr);
|
||||
} else
|
||||
{
|
||||
CriticalSectionScoped lock(_criticalSectionModulePtrs);
|
||||
@ -1115,7 +1118,9 @@ ModuleRtpRtcpImpl::SendOutgoingData(const FrameType frameType,
|
||||
timeStamp,
|
||||
payloadData,
|
||||
payloadSize,
|
||||
fragmentation);
|
||||
fragmentation,
|
||||
NULL,
|
||||
rtpTypeHdr);
|
||||
|
||||
item = _childModules.Next(item);
|
||||
}
|
||||
@ -1130,7 +1135,8 @@ ModuleRtpRtcpImpl::SendOutgoingData(const FrameType frameType,
|
||||
payloadData,
|
||||
payloadSize,
|
||||
fragmentation,
|
||||
codecInfo);
|
||||
codecInfo,
|
||||
rtpTypeHdr);
|
||||
|
||||
item = _childModules.Next(item);
|
||||
}
|
||||
|
||||
@ -27,6 +27,7 @@ class MatlabPlot;
|
||||
#endif
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
class ModuleRtpRtcpImpl : public ModuleRtpRtcpPrivate, private TMMBRHelp
|
||||
{
|
||||
public:
|
||||
@ -224,12 +225,14 @@ public:
|
||||
virtual WebRtc_Word32 RegisterSendTransport(Transport* outgoingTransport);
|
||||
|
||||
// Used by the codec module to deliver a video or audio frame for packetization
|
||||
virtual WebRtc_Word32 SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_Word8 payloadType,
|
||||
const WebRtc_UWord32 timeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation = NULL);
|
||||
virtual WebRtc_Word32
|
||||
SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_Word8 payloadType,
|
||||
const WebRtc_UWord32 timeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation = NULL,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr = NULL);
|
||||
|
||||
/*
|
||||
* RTCP
|
||||
|
||||
@ -644,7 +644,8 @@ RTPSender::SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
VideoCodecInformation* codecInfo)
|
||||
VideoCodecInformation* codecInfo,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr)
|
||||
{
|
||||
{
|
||||
// Drop this packet if we're not sending media packets
|
||||
@ -686,7 +687,8 @@ RTPSender::SendOutgoingData(const FrameType frameType,
|
||||
payloadData,
|
||||
payloadSize,
|
||||
fragmentation,
|
||||
codecInfo);
|
||||
codecInfo,
|
||||
rtpTypeHdr);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -124,13 +124,15 @@ public:
|
||||
WebRtc_Word32 SetMaxPayloadLength(const WebRtc_UWord16 length,
|
||||
const WebRtc_UWord16 packetOverHead);
|
||||
|
||||
WebRtc_Word32 SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_Word8 payloadType,
|
||||
const WebRtc_UWord32 timeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
VideoCodecInformation* codecInfo = NULL);
|
||||
WebRtc_Word32
|
||||
SendOutgoingData(const FrameType frameType,
|
||||
const WebRtc_Word8 payloadType,
|
||||
const WebRtc_UWord32 timeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
VideoCodecInformation* codecInfo = NULL,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr = NULL);
|
||||
|
||||
/*
|
||||
* NACK
|
||||
|
||||
@ -367,7 +367,8 @@ RTPSenderVideo::SendVideo(const RtpVideoCodecTypes videoType,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
VideoCodecInformation* codecInfo)
|
||||
VideoCodecInformation* codecInfo,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr)
|
||||
{
|
||||
if( payloadSize == 0)
|
||||
{
|
||||
@ -406,8 +407,8 @@ RTPSenderVideo::SendVideo(const RtpVideoCodecTypes videoType,
|
||||
payloadData, payloadSize);
|
||||
break;
|
||||
case kRtpVp8Video:
|
||||
retVal = SendVP8(frameType, payloadType, captureTimeStamp, payloadData,
|
||||
payloadSize, fragmentation);
|
||||
retVal = SendVP8(frameType, payloadType, captureTimeStamp,
|
||||
payloadData, payloadSize, fragmentation, rtpTypeHdr);
|
||||
break;
|
||||
default:
|
||||
assert(false);
|
||||
@ -1211,7 +1212,8 @@ RTPSenderVideo::SendVP8(const FrameType frameType,
|
||||
const WebRtc_UWord32 captureTimeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation)
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr)
|
||||
{
|
||||
const WebRtc_UWord16 rtpHeaderLength = _rtpSender.RTPHeaderLength();
|
||||
WebRtc_UWord16 vp8HeaderLength = 1;
|
||||
|
||||
@ -54,7 +54,8 @@ public:
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
VideoCodecInformation* codecInfo);
|
||||
VideoCodecInformation* codecInfo,
|
||||
const RTPVideoTypeHeader* rtpTypeHdr);
|
||||
|
||||
WebRtc_Word32 SendRTPIntraRequest();
|
||||
|
||||
@ -118,7 +119,9 @@ private:
|
||||
const WebRtc_UWord32 captureTimeStamp,
|
||||
const WebRtc_UWord8* payloadData,
|
||||
const WebRtc_UWord32 payloadSize,
|
||||
const RTPFragmentationHeader* fragmentation);
|
||||
const RTPFragmentationHeader* fragmentation,
|
||||
const RTPVideoTypeHeader* /*rtpTypeHdr*/);
|
||||
// TODO(hlundin): Remove comments once we start using rtpTypeHdr.
|
||||
|
||||
// MPEG 4
|
||||
WebRtc_Word32 FindMPEG4NALU(const WebRtc_UWord8* inData ,WebRtc_Word32 MaxPayloadLength);
|
||||
|
||||
Reference in New Issue
Block a user