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

Unified Diff: content/renderer/gpu/gpu_benchmarking_extension.cc

Issue 10823023: Add new fields to GPU benchmarking API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/gpu/gpu_benchmarking_extension.cc
diff --git a/content/renderer/gpu/gpu_benchmarking_extension.cc b/content/renderer/gpu/gpu_benchmarking_extension.cc
index 8590e1116b855eaadbe95d5ba3ac47d569435e58..e7c61b0602e0c23ad07f07d7eb6bf32bc5458c9a 100644
--- a/content/renderer/gpu/gpu_benchmarking_extension.cc
+++ b/content/renderer/gpu/gpu_benchmarking_extension.cc
@@ -78,6 +78,18 @@ class GpuBenchmarkingWrapper : public v8::Extension {
stats_object->Set(v8::String::New("numFramesSentToScreen"),
v8::Integer::New(stats.numFramesSentToScreen),
v8::ReadOnly);
+ if (stats.droppedFrameCount)
+ stats_object->Set(v8::String::New("droppedFrameCount"),
+ v8::Integer::New(stats.droppedFrameCount),
+ v8::ReadOnly);
+ if (stats.totalPaintTimeInSeconds)
+ stats_object->Set(v8::String::New("totalPaintTimeInSeconds"),
+ v8::Number::New(stats.totalPaintTimeInSeconds),
+ v8::ReadOnly);
+ if (stats.totalRasterizeTimeInSeconds)
+ stats_object->Set(v8::String::New("totalRasterizeTimeInSeconds"),
+ v8::Number::New(stats.totalRasterizeTimeInSeconds),
+ v8::ReadOnly);
return stats_object;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698