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

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 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 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).
miu 2016/04/26 01:25:13 nit: Consider adding a cautionary comment like: "G
xjz 2016/04/29 00:11:42 Done.
44 void ConnectToTrack(const blink::WebMediaStreamTrack& track, 47 void ConnectToTrack(const blink::WebMediaStreamTrack& track,
45 const VideoCaptureDeliverFrameCB& callback); 48 const VideoCaptureDeliverFrameCB& callback,
49 bool is_sink_secure);
46 void DisconnectFromTrack(); 50 void DisconnectFromTrack();
47 51
48 // Returns the currently-connected track, or a null instance otherwise. 52 // Returns the currently-connected track, or a null instance otherwise.
49 const blink::WebMediaStreamTrack& connected_track() const { 53 const blink::WebMediaStreamTrack& connected_track() const {
50 return connected_track_; 54 return connected_track_;
51 } 55 }
52 56
53 private: 57 private:
54 // Set by ConnectToTrack() and cleared by DisconnectFromTrack(). 58 // Set by ConnectToTrack() and cleared by DisconnectFromTrack().
55 blink::WebMediaStreamTrack connected_track_; 59 blink::WebMediaStreamTrack connected_track_;
56 }; 60 };
57 61
58 62
59 } // namespace content 63 } // namespace content
60 64
61 #endif // CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_ 65 #endif // CONTENT_PUBLIC_RENDERER_MEDIA_STREAM_VIDEO_SINK_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698