diff --git a/src/modules/rtp_rtcp/source/rtp_sender.h b/src/modules/rtp_rtcp/source/rtp_sender.h index 03c13cc519..0f27883aff 100644 --- a/src/modules/rtp_rtcp/source/rtp_sender.h +++ b/src/modules/rtp_rtcp/source/rtp_sender.h @@ -49,6 +49,7 @@ public: virtual WebRtc_UWord16 IncrementSequenceNumber() = 0; virtual WebRtc_UWord16 SequenceNumber() const = 0; virtual WebRtc_UWord16 MaxPayloadLength() const = 0; + virtual WebRtc_UWord16 MaxDataPayloadLength() const = 0; virtual WebRtc_UWord16 PacketOverHead() const = 0; virtual WebRtc_UWord16 TargetSendBitrateKbit() const = 0; virtual WebRtc_UWord16 ActualSendBitrateKbit() const = 0; diff --git a/src/modules/rtp_rtcp/source/rtp_sender_video.cc b/src/modules/rtp_rtcp/source/rtp_sender_video.cc index 3b466b27fe..c1ba25bd7a 100644 --- a/src/modules/rtp_rtcp/source/rtp_sender_video.cc +++ b/src/modules/rtp_rtcp/source/rtp_sender_video.cc @@ -1266,8 +1266,7 @@ RTPSenderVideo::SendVP8(const FrameType frameType, WebRtc_Word32 payloadBytesToSend = payloadSize; const WebRtc_UWord8* data = payloadData; - WebRtc_UWord16 maxPayloadLengthVP8 = _rtpSender.MaxPayloadLength() - - FECPacketOverhead() - rtpHeaderLength; + WebRtc_UWord16 maxPayloadLengthVP8 = _rtpSender.MaxDataPayloadLength(); assert(rtpTypeHdr); RtpFormatVp8 packetizer(data, payloadBytesToSend, rtpTypeHdr->VP8,