When Retrier succeeds, record errors it encountered.
[chromium-blink-merge.git] / webkit / media / media_stream_client.h
blob23a5ada4957db936b682b68a8ae088d1835c7763
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef WEBKIT_MEDIA_MEDIA_STREAM_CLIENT_H_
6 #define WEBKIT_MEDIA_MEDIA_STREAM_CLIENT_H_
8 #include "base/callback.h"
9 #include "base/memory/ref_counted.h"
10 #include "webkit/media/video_frame_provider.h"
12 class GURL;
14 namespace webkit_media {
16 class MediaStreamAudioRenderer;
18 // Define an interface for media stream client to get some information about
19 // the media stream.
20 class MediaStreamClient {
21 public:
22 // Check if the |url| is derived from a media stream object.
23 virtual bool IsMediaStream(const GURL& url) = 0;
25 virtual scoped_refptr<VideoFrameProvider> GetVideoFrameProvider(
26 const GURL& url,
27 const base::Closure& error_cb,
28 const VideoFrameProvider::RepaintCB& repaint_cb) = 0;
30 virtual scoped_refptr<MediaStreamAudioRenderer> GetAudioRenderer(
31 const GURL& url) = 0;
33 protected:
34 virtual ~MediaStreamClient() {}
37 } // namespace webkit_media
39 #endif // WEBKIT_MEDIA_MEDIA_STREAM_CLIENT_H_