| Index: webrtc/media/base/videoframe.h
|
| diff --git a/webrtc/media/base/videoframe.h b/webrtc/media/base/videoframe.h
|
| index 4015f906f93c4ee0894d7a7167f4d62bf1b7b7bb..1f282c5f290fba9576cd2207c0c0d30af088caa3 100644
|
| --- a/webrtc/media/base/videoframe.h
|
| +++ b/webrtc/media/base/videoframe.h
|
| @@ -19,6 +19,10 @@
|
| namespace cricket {
|
|
|
| // Represents a YUV420 (a.k.a. I420) video frame.
|
| +
|
| +// TODO(nisse): This class duplicates webrtc::VideoFrame. There's
|
| +// ongoing work to merge the classes. See
|
| +// https://bugs.chromium.org/p/webrtc/issues/detail?id=5682.
|
| class VideoFrame {
|
| public:
|
| VideoFrame() {}
|
| @@ -54,22 +58,40 @@ class VideoFrame {
|
| // Make a shallow copy of the frame. The frame buffer itself is not copied.
|
| // Both the current and new VideoFrame will share a single reference-counted
|
| // frame buffer.
|
| +
|
| + // TODO(nisse): Deprecated, to be deleted in the cricket::VideoFrame and
|
| + // webrtc::VideoFrame merge. To make a copy, use the cricket::WebRtcVideoFrame
|
| + // constructor passing video_frame_buffer(), rotation() and timestamp_us() as
|
| + // arguments.
|
| virtual VideoFrame *Copy() const = 0;
|
|
|
| // Return a copy of frame which has its pending rotation applied. The
|
| // ownership of the returned frame is held by this frame.
|
| +
|
| + // TODO(nisse): Deprecated. Should be moved or deleted in the
|
| + // cricket::VideoFrame and webrtc::VideoFrame merge, possibly with a helper
|
| + // method on VideoFrameBuffer.
|
| virtual const VideoFrame* GetCopyWithRotationApplied() const = 0;
|
|
|
| // Converts the I420 data to RGB of a certain type such as ARGB and ABGR.
|
| // Returns the frame's actual size, regardless of whether it was written or
|
| // not (like snprintf). Parameters size and stride_rgb are in units of bytes.
|
| // If there is insufficient space, nothing is written.
|
| +
|
| + // TODO(nisse): Deprecated. Should be moved or deleted in the
|
| + // cricket::VideoFrame and webrtc::VideoFrame merge. Use
|
| + // libyuv::ConvertFromI420 directly instead.
|
| virtual size_t ConvertToRgbBuffer(uint32_t to_fourcc,
|
| uint8_t* buffer,
|
| size_t size,
|
| int stride_rgb) const;
|
|
|
| - // Tests if sample is valid. Returns true if valid.
|
| + // Tests if sample is valid. Returns true if valid.
|
| +
|
| + // TODO(nisse): Deprecated. Should be deleted in the cricket::VideoFrame and
|
| + // webrtc::VideoFrame merge. Validation of sample_size possibly moved to
|
| + // libyuv::ConvertToI420. As an initial step, demote this method to protected
|
| + // status. Used only by WebRtcVideoFrame::Reset.
|
| static bool Validate(uint32_t fourcc,
|
| int w,
|
| int h,
|
|
|