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

Side by Side Diff: third_party/WebKit/public/platform/WebMediaRecorderHandler.h

Issue 2444153002: MediaRecorder: bugfix start() means buffer-forever (Closed)
Patch Set: s/start(1)/start(0)/ Created 4 years, 1 month 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
« no previous file with comments | « third_party/WebKit/Source/modules/mediarecorder/MediaRecorder.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 WebMediaRecorderHandler_h 5 #ifndef WebMediaRecorderHandler_h
6 #define WebMediaRecorderHandler_h 6 #define WebMediaRecorderHandler_h
7 7
8 #include "WebCommon.h" 8 #include "WebCommon.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 class WebMediaRecorderHandlerClient; 12 class WebMediaRecorderHandlerClient;
13 class WebMediaStream; 13 class WebMediaStream;
14 class WebString; 14 class WebString;
15 15
16 // Platform interface of a MediaRecorder. 16 // Platform interface of a MediaRecorder.
17 class BLINK_PLATFORM_EXPORT WebMediaRecorderHandler { 17 class BLINK_PLATFORM_EXPORT WebMediaRecorderHandler {
18 public: 18 public:
19 virtual ~WebMediaRecorderHandler() = default; 19 virtual ~WebMediaRecorderHandler() = default;
20 virtual bool initialize(WebMediaRecorderHandlerClient* client, 20 virtual bool initialize(WebMediaRecorderHandlerClient* client,
21 const WebMediaStream& stream, 21 const WebMediaStream& stream,
22 const WebString& type, 22 const WebString& type,
23 const WebString& codecs, 23 const WebString& codecs,
24 int32_t audioBitsPerSecond, 24 int32_t audioBitsPerSecond,
25 int32_t videoBitsPerSecond) { 25 int32_t videoBitsPerSecond) {
26 return false; 26 return false;
27 } 27 }
28 virtual bool start() { return false; }
29 virtual bool start(int timeslice) { return false; } 28 virtual bool start(int timeslice) { return false; }
30 virtual void stop() {} 29 virtual void stop() {}
31 virtual void pause() {} 30 virtual void pause() {}
32 virtual void resume() {} 31 virtual void resume() {}
33 32
34 // MediaRecorder API isTypeSupported(), which boils down to 33 // MediaRecorder API isTypeSupported(), which boils down to
35 // canSupportMimeType() [1] "If true is returned from this method, it only 34 // canSupportMimeType() [1] "If true is returned from this method, it only
36 // indicates that the MediaRecorder implementation is capable of recording 35 // indicates that the MediaRecorder implementation is capable of recording
37 // Blob objects for the specified MIME type. Recording may still fail if 36 // Blob objects for the specified MIME type. Recording may still fail if
38 // sufficient resources are not available to support the concrete media 37 // sufficient resources are not available to support the concrete media
39 // encoding." 38 // encoding."
40 // [1] https://w3c.github.io/mediacapture-record/MediaRecorder.html#methods 39 // [1] https://w3c.github.io/mediacapture-record/MediaRecorder.html#methods
41 virtual bool canSupportMimeType(const WebString& type, 40 virtual bool canSupportMimeType(const WebString& type,
42 const WebString& codecs) { 41 const WebString& codecs) {
43 return false; 42 return false;
44 } 43 }
45 }; 44 };
46 45
47 } // namespace blink 46 } // namespace blink
48 47
49 #endif // WebMediaRecorderHandler_h 48 #endif // WebMediaRecorderHandler_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/mediarecorder/MediaRecorder.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698