Change VCMFrameBuffer and VCMEncodedFrame to use rotation from base class EncodedImage.

BUG=webrtc:5687

Review-Url: https://codereview.webrtc.org/2037633002
Cr-Commit-Position: refs/heads/master@{#13376}
This commit is contained in:
perkj
2016-07-04 01:45:23 -07:00
committed by Commit bot
parent 2c332bb682
commit 414dda1a10
3 changed files with 3 additions and 7 deletions

View File

@ -22,7 +22,6 @@ VCMEncodedFrame::VCMEncodedFrame()
_missingFrame(false), _missingFrame(false),
_codec(kVideoCodecUnknown), _codec(kVideoCodecUnknown),
_fragmentation(), _fragmentation(),
_rotation(kVideoRotation_0),
_rotation_set(false) { _rotation_set(false) {
_codecSpecificInfo.codecType = kVideoCodecUnknown; _codecSpecificInfo.codecType = kVideoCodecUnknown;
} }
@ -34,7 +33,6 @@ VCMEncodedFrame::VCMEncodedFrame(const webrtc::EncodedImage& rhs)
_missingFrame(false), _missingFrame(false),
_codec(kVideoCodecUnknown), _codec(kVideoCodecUnknown),
_fragmentation(), _fragmentation(),
_rotation(kVideoRotation_0),
_rotation_set(false) { _rotation_set(false) {
_codecSpecificInfo.codecType = kVideoCodecUnknown; _codecSpecificInfo.codecType = kVideoCodecUnknown;
_buffer = NULL; _buffer = NULL;
@ -55,7 +53,6 @@ VCMEncodedFrame::VCMEncodedFrame(const VCMEncodedFrame& rhs)
_codecSpecificInfo(rhs._codecSpecificInfo), _codecSpecificInfo(rhs._codecSpecificInfo),
_codec(rhs._codec), _codec(rhs._codec),
_fragmentation(), _fragmentation(),
_rotation(rhs._rotation),
_rotation_set(rhs._rotation_set) { _rotation_set(rhs._rotation_set) {
_buffer = NULL; _buffer = NULL;
_size = 0; _size = 0;
@ -93,7 +90,7 @@ void VCMEncodedFrame::Reset() {
_length = 0; _length = 0;
_codecSpecificInfo.codecType = kVideoCodecUnknown; _codecSpecificInfo.codecType = kVideoCodecUnknown;
_codec = kVideoCodecUnknown; _codec = kVideoCodecUnknown;
_rotation = kVideoRotation_0; rotation_ = kVideoRotation_0;
_rotation_set = false; _rotation_set = false;
} }

View File

@ -75,7 +75,7 @@ class VCMEncodedFrame : protected EncodedImage {
/** /**
* Get frame rotation * Get frame rotation
*/ */
VideoRotation rotation() const { return _rotation; } VideoRotation rotation() const { return rotation_; }
/** /**
* True if this frame is complete, false otherwise * True if this frame is complete, false otherwise
*/ */
@ -119,7 +119,6 @@ class VCMEncodedFrame : protected EncodedImage {
CodecSpecificInfo _codecSpecificInfo; CodecSpecificInfo _codecSpecificInfo;
webrtc::VideoCodecType _codec; webrtc::VideoCodecType _codec;
RTPFragmentationHeader _fragmentation; RTPFragmentationHeader _fragmentation;
VideoRotation _rotation;
// Video rotation is only set along with the last packet for each frame // Video rotation is only set along with the last packet for each frame
// (same as marker bit). This |_rotation_set| is only for debugging purpose // (same as marker bit). This |_rotation_set| is only for debugging purpose

View File

@ -153,7 +153,7 @@ VCMFrameBufferEnum VCMFrameBuffer::InsertPacket(
// (HEVC)). // (HEVC)).
if (packet.markerBit) { if (packet.markerBit) {
RTC_DCHECK(!_rotation_set); RTC_DCHECK(!_rotation_set);
_rotation = packet.video_header.rotation; rotation_ = packet.video_header.rotation;
_rotation_set = true; _rotation_set = true;
} }