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

Side by Side Diff: webrtc/call/rtc_event_log.h

Issue 1374253002: Added functions on libjingle API to start and stop the recording of an RtcEventLog. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Added functions to start and stop logging. Created 5 years, 2 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 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 #ifndef WEBRTC_CALL_RTC_EVENT_LOG_H_ 11 #ifndef WEBRTC_CALL_RTC_EVENT_LOG_H_
12 #define WEBRTC_CALL_RTC_EVENT_LOG_H_ 12 #define WEBRTC_CALL_RTC_EVENT_LOG_H_
13 13
14 #include <stdio.h>
15
14 #include <string> 16 #include <string>
15 17
16 #include "webrtc/base/scoped_ptr.h" 18 #include "webrtc/base/scoped_ptr.h"
17 #include "webrtc/video_receive_stream.h" 19 #include "webrtc/video_receive_stream.h"
18 #include "webrtc/video_send_stream.h" 20 #include "webrtc/video_send_stream.h"
19 21
20 namespace webrtc { 22 namespace webrtc {
21 23
22 // Forward declaration of storage class that is automatically generated from 24 // Forward declaration of storage class that is automatically generated from
23 // the protobuf file. 25 // the protobuf file.
(...skipping 10 matching lines...) Expand all
34 virtual ~RtcEventLog() {} 36 virtual ~RtcEventLog() {}
35 37
36 static rtc::scoped_ptr<RtcEventLog> Create(); 38 static rtc::scoped_ptr<RtcEventLog> Create();
37 39
38 // Starts logging for the specified duration to the specified file. 40 // Starts logging for the specified duration to the specified file.
39 // The logging will stop automatically after the specified duration. 41 // The logging will stop automatically after the specified duration.
40 // If the file already exists it will be overwritten. 42 // If the file already exists it will be overwritten.
41 // If the file cannot be opened, the RtcEventLog will not start logging. 43 // If the file cannot be opened, the RtcEventLog will not start logging.
42 virtual void StartLogging(const std::string& file_name, int duration_ms) = 0; 44 virtual void StartLogging(const std::string& file_name, int duration_ms) = 0;
43 45
46 // Starts logging until either the 10 minute timer runs out or the StopLogging
47 // function is called. This function uses an already opened file pointer, and
48 // will return 0 on success.
49 virtual int StartLogging(FILE* log_file) = 0;
terelius 2015/10/02 10:07:14 Maybe make this function return a bool? What is th
50
44 virtual void StopLogging() = 0; 51 virtual void StopLogging() = 0;
45 52
46 // Logs configuration information for webrtc::VideoReceiveStream 53 // Logs configuration information for webrtc::VideoReceiveStream
47 virtual void LogVideoReceiveStreamConfig( 54 virtual void LogVideoReceiveStreamConfig(
48 const webrtc::VideoReceiveStream::Config& config) = 0; 55 const webrtc::VideoReceiveStream::Config& config) = 0;
49 56
50 // Logs configuration information for webrtc::VideoSendStream 57 // Logs configuration information for webrtc::VideoSendStream
51 virtual void LogVideoSendStreamConfig( 58 virtual void LogVideoSendStreamConfig(
52 const webrtc::VideoSendStream::Config& config) = 0; 59 const webrtc::VideoSendStream::Config& config) = 0;
53 60
(...skipping 15 matching lines...) Expand all
69 76
70 // Reads an RtcEventLog file and returns true when reading was successful. 77 // Reads an RtcEventLog file and returns true when reading was successful.
71 // The result is stored in the given EventStream object. 78 // The result is stored in the given EventStream object.
72 static bool ParseRtcEventLog(const std::string& file_name, 79 static bool ParseRtcEventLog(const std::string& file_name,
73 rtclog::EventStream* result); 80 rtclog::EventStream* result);
74 }; 81 };
75 82
76 } // namespace webrtc 83 } // namespace webrtc
77 84
78 #endif // WEBRTC_CALL_RTC_EVENT_LOG_H_ 85 #endif // WEBRTC_CALL_RTC_EVENT_LOG_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698