| Index: content/renderer/media/video_capture_impl.h
|
| diff --git a/content/renderer/media/video_capture_impl.h b/content/renderer/media/video_capture_impl.h
|
| index e03a2fb1a2d466a9986e2b8228db83ed9acf35a1..df077c999e9d2bda3353bffe008ef651f214d9e1 100644
|
| --- a/content/renderer/media/video_capture_impl.h
|
| +++ b/content/renderer/media/video_capture_impl.h
|
| @@ -84,20 +84,25 @@ class CONTENT_EXPORT VideoCaptureImpl
|
| // Carries a shared memory for transferring video frames from browser to
|
| // renderer.
|
| class ClientBuffer;
|
| + class ClientBuffer2;
|
|
|
| // VideoCaptureMessageFilter::Delegate interface.
|
| void OnBufferCreated(base::SharedMemoryHandle handle,
|
| int length,
|
| int buffer_id) override;
|
| + void OnBufferCreated2(const std::vector<gfx::GpuMemoryBufferHandle>& handles,
|
| + const gfx::Size& size,
|
| + int buffer_id) override;
|
| void OnBufferDestroyed(int buffer_id) override;
|
| - void OnBufferReceived(int buffer_id,
|
| - base::TimeTicks timestamp,
|
| - const base::DictionaryValue& metadata,
|
| - media::VideoPixelFormat pixel_format,
|
| - media::VideoFrame::StorageType storage_type,
|
| - const gfx::Size& coded_size,
|
| - const gfx::Rect& visible_rect,
|
| - const gpu::MailboxHolder& mailbox_holder) override;
|
| + void OnBufferReceived(
|
| + int buffer_id,
|
| + base::TimeTicks timestamp,
|
| + const base::DictionaryValue& metadata,
|
| + media::VideoPixelFormat pixel_format,
|
| + media::VideoFrame::StorageType storage_type,
|
| + const gfx::Size& coded_size,
|
| + const gfx::Rect& visible_rect,
|
| + const gpu::MailboxHolder& mailbox_holder) override;
|
| void OnStateChanged(VideoCaptureState state) override;
|
| void OnDeviceSupportedFormatsEnumerated(
|
| const media::VideoCaptureFormats& supported_formats) override;
|
| @@ -107,10 +112,16 @@ class CONTENT_EXPORT VideoCaptureImpl
|
|
|
| // Sends an IPC message to browser process when all clients are done with the
|
| // buffer.
|
| - void OnClientBufferFinished(int buffer_id,
|
| - const scoped_refptr<ClientBuffer>& buffer,
|
| - uint32 release_sync_point,
|
| - double consumer_resource_utilization);
|
| + void OnClientBufferFinished(
|
| + int buffer_id,
|
| + const scoped_refptr<ClientBuffer>& buffer,
|
| + uint32 release_sync_point,
|
| + double consumer_resource_utilization);
|
| + void OnClientBufferFinished2(
|
| + int buffer_id,
|
| + const scoped_refptr<ClientBuffer2>& buffer,
|
| + uint32 release_sync_point,
|
| + double consumer_resource_utilization);
|
|
|
| void StopDevice();
|
| void RestartCapture();
|
| @@ -147,8 +158,10 @@ class CONTENT_EXPORT VideoCaptureImpl
|
| std::vector<VideoCaptureDeviceFormatsCB> device_formats_in_use_cb_queue_;
|
|
|
| // Buffers available for sending to the client.
|
| - typedef std::map<int32, scoped_refptr<ClientBuffer> > ClientBufferMap;
|
| + typedef std::map<int32, scoped_refptr<ClientBuffer>> ClientBufferMap;
|
| ClientBufferMap client_buffers_;
|
| + typedef std::map<int32, scoped_refptr<ClientBuffer2>> ClientBuffer2Map;
|
| + ClientBuffer2Map client_buffer2s_;
|
|
|
| // Track information for the video capture client, consisting of parameters
|
| // for capturing and callbacks to the client.
|
|
|