Index: content/common/gpu/media/exynos_v4l2_video_device.h |
diff --git a/content/common/gpu/media/exynos_v4l2_video_device.h b/content/common/gpu/media/exynos_v4l2_video_device.h |
index 39c3428523ec1fca2ec8a05d8430416e70dd2fbf..da758de1b08077e9fccb9f062134b31e0f652391 100644 |
--- a/content/common/gpu/media/exynos_v4l2_video_device.h |
+++ b/content/common/gpu/media/exynos_v4l2_video_device.h |
@@ -18,21 +18,39 @@ class ExynosV4L2Device : public V4L2Device { |
virtual ~ExynosV4L2Device(); |
// V4L2Device implementation. |
- int Ioctl(int request, void* arg) OVERRIDE; |
- bool Poll(bool poll_device, bool* event_pending) OVERRIDE; |
- bool SetDevicePollInterrupt() OVERRIDE; |
- bool ClearDevicePollInterrupt() OVERRIDE; |
- void* Mmap(void* addr, |
- unsigned int len, |
- int prot, |
- int flags, |
- unsigned int offset) OVERRIDE; |
- void Munmap(void* addr, unsigned int len) OVERRIDE; |
- |
- // Does all the initialization of device fds, returns true on success. |
- bool Initialize(); |
+ virtual int Ioctl(int request, void* arg) OVERRIDE; |
+ virtual bool Poll(bool poll_device, bool* event_pending) OVERRIDE; |
+ virtual bool SetDevicePollInterrupt() OVERRIDE; |
+ virtual bool ClearDevicePollInterrupt() OVERRIDE; |
+ virtual void* Mmap(void* addr, |
+ unsigned int len, |
+ int prot, |
+ int flags, |
+ unsigned int offset) OVERRIDE; |
+ virtual void Munmap(void* addr, unsigned int len) OVERRIDE; |
+ virtual bool Initialize() OVERRIDE; |
+ virtual EGLImageKHR CreateEGLImage(EGLDisplay egl_display, |
+ GLuint texture_id, |
+ gfx::Size frame_buffer_size, |
+ unsigned int buffer_index, |
+ unsigned int total_buffers) OVERRIDE; |
+ virtual void DestroyEGLImage(unsigned int buffer_index) OVERRIDE; |
+ virtual GLenum GetTextureTarget() OVERRIDE; |
+ virtual uint32 GetCapturePixelFormat() OVERRIDE; |
+ virtual uint8 GetNumberOfPlanes() OVERRIDE; |
private: |
+ // Record for output buffer. |
+ struct DeviceOutputRecord { |
+ DeviceOutputRecord(); |
+ ~DeviceOutputRecord(); |
+ int fds[2]; // file descriptors for each plane. |
+ EGLImageKHR egl_image; // EGLImageKHR for the output buffer. |
+ }; |
sheu
2014/03/27 02:00:23
Since we already have the output buffers being tra
shivdasp
2014/03/27 02:41:04
Ohh I did not know that the fd can be closed immed
Pawel Osciak
2014/03/27 05:18:06
John is right.
To add more detail: the owner of b
|
+ |
+ // Mapping of int index to output buffer record. |
+ std::vector<DeviceOutputRecord> device_output_buffer_map_; |
+ |
// The actual device fd. |
int device_fd_; |