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

Unified Diff: webrtc/modules/video_coding/codecs/test/videoprocessor.cc

Issue 2890223002: Update plot_webrtc_test_logs.py: (Closed)
Patch Set: Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/video_coding/codecs/test/videoprocessor.cc
diff --git a/webrtc/modules/video_coding/codecs/test/videoprocessor.cc b/webrtc/modules/video_coding/codecs/test/videoprocessor.cc
index 3a918f6cacb88225ae71598e03786c12025fe250..623c417ff53bdfab4f0b3d840d906c0df5d13d34 100644
--- a/webrtc/modules/video_coding/codecs/test/videoprocessor.cc
+++ b/webrtc/modules/video_coding/codecs/test/videoprocessor.cc
@@ -139,6 +139,7 @@ VideoProcessorImpl::VideoProcessorImpl(webrtc::VideoEncoder* encoder,
source_frame_writer_(source_frame_writer),
encoded_frame_writer_(encoded_frame_writer),
decoded_frame_writer_(decoded_frame_writer),
+ bit_rate_factor_(config.codec_settings->maxFramerate * 0.001 * 8),
initialized_(false),
last_encoded_frame_num_(-1),
last_decoded_frame_num_(-1),
@@ -146,8 +147,7 @@ VideoProcessorImpl::VideoProcessorImpl(webrtc::VideoEncoder* encoder,
last_decoded_frame_buffer_(0, analysis_frame_reader->FrameLength()),
stats_(stats),
num_dropped_frames_(0),
- num_spatial_resizes_(0),
- bit_rate_factor_(0.0) {
+ num_spatial_resizes_(0) {
RTC_DCHECK(encoder);
RTC_DCHECK(decoder);
RTC_DCHECK(packet_manipulator);
@@ -162,9 +162,6 @@ bool VideoProcessorImpl::Init() {
RTC_DCHECK(!initialized_)
<< "This VideoProcessor has already been initialized.";
- // Calculate a factor used for bit rate calculations.
- bit_rate_factor_ = config_.codec_settings->maxFramerate * 0.001 * 8; // bits
-
// Setup required callbacks for the encoder/decoder.
RTC_CHECK_EQ(encoder_->RegisterEncodeCompleteCallback(encode_callback_.get()),
WEBRTC_VIDEO_CODEC_OK)
@@ -195,6 +192,13 @@ bool VideoProcessorImpl::Init() {
encoder_->ImplementationName());
printf(" Decoder implementation name: %s\n",
decoder_->ImplementationName());
+ if (strcmp(encoder_->ImplementationName(),
+ decoder_->ImplementationName()) == 0) {
+ printf(" Codec implementation name: %s_%s\n",
+ CodecTypeToPayloadName(config_.codec_settings->codecType)
+ .value_or("Unknown"),
+ encoder_->ImplementationName());
+ }
PrintCodecSettings(config_.codec_settings);
}

Powered by Google App Engine
This is Rietveld 408576698