Index: media/base/video_frame.h |
diff --git a/media/base/video_frame.h b/media/base/video_frame.h |
index 80169cbe822990ca487fa5993d12bc2c5a7aa0d0..aba6f2e98dd3d65a1e1eb75b4841815b60e1c67d 100644 |
--- a/media/base/video_frame.h |
+++ b/media/base/video_frame.h |
@@ -297,6 +297,9 @@ class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> { |
int stride(size_t plane) const; |
+ // Returns the actual allocated size for a frame. |
+ size_t allocated_size() const; |
DaleCurtis
2015/08/04 19:07:44
Return inline.
emircan
2015/08/04 19:54:35
Done.
|
+ |
// Returns the number of bytes per row and number of rows for a given plane. |
// |
// As opposed to stride(), row_bytes() refers to the bytes representing |
@@ -444,6 +447,9 @@ class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> { |
// strides can be negative. |
int32 strides_[kMaxPlanes]; |
+ // Actual allocation size for a YUV frame with alignments and padding. |
+ size_t allocated_size_; |
+ |
// Array of data pointers to each plane. |
// TODO(mcasas): we don't know on ctor if we own |data_| or not. After |
// refactoring VideoFrame, change to scoped_ptr<uint8, AlignedFreeDeleter>. |