Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(245)

Side by Side Diff: content/renderer/media/video_capture_impl_manager.h

Issue 1873293002: Report if video capturing meets output protection requirement. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments. Rebased. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_
6 #define CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_ 6 #define CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 10
11 #include "base/callback.h" 11 #include "base/callback.h"
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/memory/weak_ptr.h" 14 #include "base/memory/weak_ptr.h"
15 #include "base/single_thread_task_runner.h" 15 #include "base/single_thread_task_runner.h"
16 #include "base/synchronization/lock.h" 16 #include "base/synchronization/lock.h"
17 #include "base/threading/thread_checker.h" 17 #include "base/threading/thread_checker.h"
18 #include "content/common/content_export.h" 18 #include "content/common/content_export.h"
19 #include "content/common/media/video_capture.h" 19 #include "content/common/media/video_capture.h"
20 #include "content/public/common/media_stream_request.h"
20 #include "content/public/renderer/media_stream_video_sink.h" 21 #include "content/public/renderer/media_stream_video_sink.h"
21 #include "media/base/video_capture_types.h" 22 #include "media/base/video_capture_types.h"
22 23
23 namespace content { 24 namespace content {
24 25
25 class VideoCaptureImpl; 26 class VideoCaptureImpl;
26 class VideoCaptureMessageFilter; 27 class VideoCaptureMessageFilter;
27 28
28 // TODO(hclam): This class should be renamed to VideoCaptureService. 29 // TODO(hclam): This class should be renamed to VideoCaptureService.
29 30
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 base::Closure StartCapture( 71 base::Closure StartCapture(
71 media::VideoCaptureSessionId id, 72 media::VideoCaptureSessionId id,
72 const media::VideoCaptureParams& params, 73 const media::VideoCaptureParams& params,
73 const VideoCaptureStateUpdateCB& state_update_cb, 74 const VideoCaptureStateUpdateCB& state_update_cb,
74 const VideoCaptureDeliverFrameCB& deliver_frame_cb); 75 const VideoCaptureDeliverFrameCB& deliver_frame_cb);
75 76
76 // Requests that the video capturer send a frame "soon" (e.g., to resolve 77 // Requests that the video capturer send a frame "soon" (e.g., to resolve
77 // picture loss or quality issues). 78 // picture loss or quality issues).
78 void RequestRefreshFrame(media::VideoCaptureSessionId id); 79 void RequestRefreshFrame(media::VideoCaptureSessionId id);
79 80
81 // Set if the video capturing link is secure.
82 void SetCapturingLinkSecured(content::MediaStreamType type,
83 media::VideoCaptureSessionId id,
84 bool is_secure);
85
80 // Get supported formats supported by the device for the given session 86 // Get supported formats supported by the device for the given session
81 // ID. |callback| will be called on the IO thread. 87 // ID. |callback| will be called on the IO thread.
82 void GetDeviceSupportedFormats(media::VideoCaptureSessionId id, 88 void GetDeviceSupportedFormats(media::VideoCaptureSessionId id,
83 const VideoCaptureDeviceFormatsCB& callback); 89 const VideoCaptureDeviceFormatsCB& callback);
84 90
85 // Get supported formats currently in use for the given session ID. 91 // Get supported formats currently in use for the given session ID.
86 // |callback| will be called on the IO thread. 92 // |callback| will be called on the IO thread.
87 void GetDeviceFormatsInUse(media::VideoCaptureSessionId id, 93 void GetDeviceFormatsInUse(media::VideoCaptureSessionId id,
88 const VideoCaptureDeviceFormatsCB& callback); 94 const VideoCaptureDeviceFormatsCB& callback);
89 95
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // Bound to the render thread. 131 // Bound to the render thread.
126 // NOTE: Weak pointers must be invalidated before all other member variables. 132 // NOTE: Weak pointers must be invalidated before all other member variables.
127 base::WeakPtrFactory<VideoCaptureImplManager> weak_factory_; 133 base::WeakPtrFactory<VideoCaptureImplManager> weak_factory_;
128 134
129 DISALLOW_COPY_AND_ASSIGN(VideoCaptureImplManager); 135 DISALLOW_COPY_AND_ASSIGN(VideoCaptureImplManager);
130 }; 136 };
131 137
132 } // namespace content 138 } // namespace content
133 139
134 #endif // CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_ 140 #endif // CONTENT_RENDERER_MEDIA_VIDEO_CAPTURE_IMPL_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698