Index: content/renderer/media/media_stream_video_source.h |
=================================================================== |
--- content/renderer/media/media_stream_video_source.h (revision 0) |
+++ content/renderer/media/media_stream_video_source.h (revision 0) |
@@ -0,0 +1,44 @@ |
+// Copyright 2013 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_SOURCE_H_ |
+#define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_SOURCE_H_ |
+ |
+#include "base/compiler_specific.h" |
+#include "base/memory/ref_counted.h" |
+#include "content/common/content_export.h" |
+#include "content/renderer/media/media_stream_source_extra_data.h" |
+#include "third_party/WebKit/public/platform/WebMediaConstraints.h" |
+#include "third_party/WebKit/public/platform/WebMediaStreamSource.h" |
+#include "third_party/WebKit/public/platform/WebMediaStreamTrack.h" |
+ |
+namespace media { |
+class VideoFrame; |
+} |
+ |
+namespace content { |
+ |
+// MediaStreamVideoSource is an interface used for sending video frames to a |
+// MediaStreamVideoTrack. |
+// http://dev.w3.org/2011/webrtc/editor/getusermedia.html |
+// All methods calls will be done from the main render thread. |
+class CONTENT_EXPORT MediaStreamVideoSource |
+ : public MediaStreamSourceExtraData { |
+ public: |
+ void AddTrack(const blink::WebMediaStreamTrack& track, |
+ const blink::WebMediaConstraints& constraints); |
+ |
+ void RemoveTrack(const blink::WebMediaStreamTrack& track); |
+ |
+ void SetReadyState(blink::WebMediaStreamSource::ReadyState state); |
perkj_chrome
2014/01/05 15:38:03
Can SetReadyState and PutVideoFrame be protected i
Ronghua Wu (Left Chromium)
2014/01/06 19:41:15
Done.
|
+ |
+ // Delivers |frame| to registered tracks according to their constraints. |
+ virtual void PutVideoFrame(const scoped_refptr<media::VideoFrame>& frame); |
+ |
+ virtual ~MediaStreamVideoSource(); |
+}; |
+ |
+} // namespace content |
+ |
+#endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_SOURCE_H_ |
Property changes on: content/renderer/media/media_stream_video_source.h |
___________________________________________________________________ |
Added: svn:eol-style |
+ LF |