Move the call to GetBitstream out of the RtpFrameObject ctor.

Bug: webrtc:10979
Change-Id: I9159eb04d4a371e8ed8f932a989d6b884faa7be7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/153661
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29237}
This commit is contained in:
philipel
2019-09-19 11:22:22 +02:00
committed by Commit Bot
parent 14137a1064
commit 76161f7446
3 changed files with 11 additions and 8 deletions

View File

@ -58,10 +58,6 @@ RtpFrameObject::RtpFrameObject(PacketBuffer* packet_buffer,
// as of the first packet's.
SetPlayoutDelay(first_packet->video_header.playout_delay);
// TODO(nisse): Change GetBitstream to return the buffer?
SetEncodedData(EncodedImageBuffer::Create(frame_size));
bool bitstream_copied = packet_buffer->GetBitstream(*this, data());
RTC_DCHECK(bitstream_copied);
_encodedWidth = first_packet->width();
_encodedHeight = first_packet->height();