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

Unified Diff: webrtc/video/video_decoder.cc

Issue 1406903002: Expose codec implementation names in stats. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: report what we fell back from 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/video/video_decoder.cc
diff --git a/webrtc/video/video_decoder.cc b/webrtc/video/video_decoder.cc
index e8dc5f1c296127afff252f1b6c8e6a0c47c69fa4..462b0afdef6766cfc060d021b8260b92d8e239bd 100644
--- a/webrtc/video/video_decoder.cc
+++ b/webrtc/video/video_decoder.cc
@@ -76,6 +76,9 @@ bool VideoDecoderSoftwareFallbackWrapper::InitFallbackDecoder() {
}
if (callback_ != nullptr)
fallback_decoder_->RegisterDecodeCompleteCallback(callback_);
+ fallback_implementation_name_ =
+ std::string(fallback_decoder_->ImplementationName()) +
+ " (fallback from: " + decoder_->ImplementationName() + ")";
return true;
}
@@ -131,4 +134,10 @@ int32_t VideoDecoderSoftwareFallbackWrapper::Reset() {
return decoder_->Reset();
}
+const char* VideoDecoderSoftwareFallbackWrapper::ImplementationName() const {
+ if (fallback_decoder_)
+ return fallback_implementation_name_.c_str();
+ return decoder_->ImplementationName();
+}
+
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698