OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER_H_ | 5 #ifndef SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER_H_ |
6 #define SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER_H_ | 6 #define SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER_H_ |
7 | 7 |
8 #include "media/capture/video/video_capture_device.h" | 8 #include "media/capture/video/video_capture_device.h" |
9 #include "services/video_capture/public/interfaces/device.mojom.h" | 9 #include "services/video_capture/public/interfaces/device.mojom.h" |
10 | 10 |
11 namespace video_capture { | 11 namespace video_capture { |
12 | 12 |
13 // Adapter that allows a video_capture::mojom::Device to be used in place of | 13 // Adapter that allows a video_capture::mojom::Device to be used in place of |
14 // a media::VideoFrameConsumerFeedbackObserver | 14 // a media::VideoFrameConsumerFeedbackObserver |
15 class DeviceToFeedbackObserverAdapter | 15 class DeviceToFeedbackObserverAdapter |
16 : public media::VideoFrameConsumerFeedbackObserver { | 16 : public media::VideoFrameConsumerFeedbackObserver { |
17 public: | 17 public: |
18 DeviceToFeedbackObserverAdapter(mojom::DevicePtr device); | 18 DeviceToFeedbackObserverAdapter(mojom::DevicePtr* device); |
19 ~DeviceToFeedbackObserverAdapter() override; | 19 ~DeviceToFeedbackObserverAdapter() override; |
20 | 20 |
21 // media::VideoFrameConsumerFeedbackObserver: | 21 // media::VideoFrameConsumerFeedbackObserver: |
22 void OnUtilizationReport(int frame_feedback_id, double utilization) override; | 22 void OnUtilizationReport(int frame_feedback_id, double utilization) override; |
23 | 23 |
24 private: | 24 private: |
25 mojom::DevicePtr device_; | 25 mojom::DevicePtr* device_; |
mcasas
2017/04/27 00:22:15
I'm surprised by this change, it seems unrelated t
chfremer
2017/04/27 19:52:49
Thanks for catching this. You are right, this chan
| |
26 }; | 26 }; |
27 | 27 |
28 } // namespace video_capture | 28 } // namespace video_capture |
29 | 29 |
30 #endif // SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER _H_ | 30 #endif // SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_DEVICE_TO_FEEDBACK_OBSERVER_ADAPTER _H_ |
OLD | NEW |