OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2011 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 |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 FileOutputFrameReceiver::FileOutputFrameReceiver( | 66 FileOutputFrameReceiver::FileOutputFrameReceiver( |
67 const std::string& base_out_filename, uint32_t ssrc) | 67 const std::string& base_out_filename, uint32_t ssrc) |
68 : out_filename_(), | 68 : out_filename_(), |
69 out_file_(NULL), | 69 out_file_(NULL), |
70 timing_file_(NULL), | 70 timing_file_(NULL), |
71 width_(0), | 71 width_(0), |
72 height_(0), | 72 height_(0), |
73 count_(0) { | 73 count_(0) { |
74 std::string basename; | 74 std::string basename; |
75 std::string extension; | 75 std::string extension; |
76 if (base_out_filename == "") { | 76 if (base_out_filename.empty()) { |
77 basename = webrtc::test::OutputPath() + "rtp_decoded"; | 77 basename = webrtc::test::OutputPath() + "rtp_decoded"; |
78 extension = "yuv"; | 78 extension = "yuv"; |
79 } else { | 79 } else { |
80 SplitFilename(base_out_filename, &basename, &extension); | 80 SplitFilename(base_out_filename, &basename, &extension); |
81 } | 81 } |
82 std::stringstream ss; | 82 std::stringstream ss; |
83 ss << basename << "_" << std::hex << std::setw(8) << std::setfill('0') << | 83 ss << basename << "_" << std::hex << std::setw(8) << std::setfill('0') << |
84 ssrc << "." << extension; | 84 ssrc << "." << extension; |
85 out_filename_ = ss.str(); | 85 out_filename_ = ss.str(); |
86 } | 86 } |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 } | 130 } |
131 | 131 |
132 webrtc::RtpVideoCodecTypes ConvertCodecType(const char* plname) { | 132 webrtc::RtpVideoCodecTypes ConvertCodecType(const char* plname) { |
133 if (strncmp(plname,"VP8" , 3) == 0) { | 133 if (strncmp(plname,"VP8" , 3) == 0) { |
134 return webrtc::kRtpVideoVp8; | 134 return webrtc::kRtpVideoVp8; |
135 } else { | 135 } else { |
136 // Default value. | 136 // Default value. |
137 return webrtc::kRtpVideoGeneric; | 137 return webrtc::kRtpVideoGeneric; |
138 } | 138 } |
139 } | 139 } |
OLD | NEW |