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

Side by Side Diff: content/public/renderer/media_stream_video_sink.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 oshima and nasko's comments, and rebased. Created 4 years, 7 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_ 5 #ifndef CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_
6 #define CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_ 6 #define CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 23 matching lines...) Expand all
34 // is destroyed, DisconnectFromTrack must be called. This MediaStreamVideoSink 34 // is destroyed, DisconnectFromTrack must be called. This MediaStreamVideoSink
35 // base class holds a reference to the WebMediaStreamTrack until 35 // base class holds a reference to the WebMediaStreamTrack until
36 // DisconnectFromTrack is called. 36 // DisconnectFromTrack is called.
37 // 37 //
38 // Calls to these methods must be done on the main render thread. 38 // Calls to these methods must be done on the main render thread.
39 // Note that |callback| for frame delivery happens on the IO thread. 39 // Note that |callback| for frame delivery happens on the IO thread.
40 // 40 //
41 // Warning: Calling DisconnectFromTrack does not immediately stop frame 41 // Warning: Calling DisconnectFromTrack does not immediately stop frame
42 // delivery through the |callback|, since frames are being delivered on a 42 // delivery through the |callback|, since frames are being delivered on a
43 // different thread. 43 // different thread.
44 //
45 // |is_sink_secure| indicates if this MediaStreamVideoSink is secure (i.e.
46 // meets output protection requirement). Generally, this should be false
47 // unless you know what you are doing.
44 void ConnectToTrack(const blink::WebMediaStreamTrack& track, 48 void ConnectToTrack(const blink::WebMediaStreamTrack& track,
45 const VideoCaptureDeliverFrameCB& callback); 49 const VideoCaptureDeliverFrameCB& callback,
50 bool is_sink_secure);
46 void DisconnectFromTrack(); 51 void DisconnectFromTrack();
47 52
48 // Returns the currently-connected track, or a null instance otherwise. 53 // Returns the currently-connected track, or a null instance otherwise.
49 const blink::WebMediaStreamTrack& connected_track() const { 54 const blink::WebMediaStreamTrack& connected_track() const {
50 return connected_track_; 55 return connected_track_;
51 } 56 }
52 57
53 private: 58 private:
54 // Set by ConnectToTrack() and cleared by DisconnectFromTrack(). 59 // Set by ConnectToTrack() and cleared by DisconnectFromTrack().
55 blink::WebMediaStreamTrack connected_track_; 60 blink::WebMediaStreamTrack connected_track_;
56 }; 61 };
57 62
58 63
59 } // namespace content 64 } // namespace content
60 65
61 #endif // CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_ 66 #endif // CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_
OLDNEW
« no previous file with comments | « content/public/browser/media_observer.h ('k') | content/public/renderer/media_stream_video_sink.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698