Index: media/base/video_frame.h |
diff --git a/media/base/video_frame.h b/media/base/video_frame.h |
index 5341c16d610bccc75715b2cc2cbc89d14d2ac628..0ad06286fc10143eb5cd04e714a385c3883f1fb5 100644 |
--- a/media/base/video_frame.h |
+++ b/media/base/video_frame.h |
@@ -36,6 +36,12 @@ class VideoFrame : public StreamSample { |
EMPTY, // An empty frame. |
}; |
+ enum BufferType { |
+ TYPE_SYSTEM_MEMORY, |
+ TYPE_OMX_BUFFER_HEAD, |
+ TYPE_EGL_IMAGE, |
+ }; |
+ |
public: |
// Creates a new frame with given parameters. Buffers for the frame are |
// allocated but not initialized. |
@@ -55,6 +61,8 @@ class VideoFrame : public StreamSample { |
static void CreateBlackFrame(int width, int height, |
scoped_refptr<VideoFrame>* frame_out); |
+ virtual BufferType type() const { return TYPE_SYSTEM_MEMORY; } |
+ |
Format format() const { return format_; } |
size_t width() const { return width_; } |
@@ -80,7 +88,7 @@ class VideoFrame : public StreamSample { |
repeat_count_ = repeat_count; |
} |
- private: |
+ protected: |
// Clients must use the static CreateFrame() method to create a new frame. |
VideoFrame(Format format, |
size_t video_width, |