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

Unified Diff: cc/overdraw_metrics.cc

Issue 11308153: Migrate most of cc/ from WebKit::WebTransformationMatrix to gfx::Transform (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch for landing Created 8 years, 1 month 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 | « cc/overdraw_metrics.h ('k') | cc/quad_culler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/overdraw_metrics.cc
diff --git a/cc/overdraw_metrics.cc b/cc/overdraw_metrics.cc
index 1f9435784bc7e451b79d528dd1665b2e52e92bf1..8f4df245ed0a6a5ff181d3d6a509d86a57bce357 100644
--- a/cc/overdraw_metrics.cc
+++ b/cc/overdraw_metrics.cc
@@ -11,9 +11,7 @@
#include "cc/math_util.h"
#include "ui/gfx/quad_f.h"
#include "ui/gfx/rect.h"
-#include <public/WebTransformationMatrix.h>
-
-using WebKit::WebTransformationMatrix;
+#include "ui/gfx/transform.h"
namespace cc {
@@ -49,7 +47,7 @@ static inline float polygonArea(const gfx::PointF points[8], int numPoints)
}
// Takes a given quad, maps it by the given transformation, and gives the area of the resulting polygon.
-static inline float areaOfMappedQuad(const WebTransformationMatrix& transform, const gfx::QuadF& quad)
+static inline float areaOfMappedQuad(const gfx::Transform& transform, const gfx::QuadF& quad)
{
gfx::PointF clippedQuad[8];
int numVerticesInClippedQuad = 0;
@@ -71,7 +69,7 @@ void OverdrawMetrics::didCullTilesForUpload(int count)
m_tilesCulledForUpload += count;
}
-void OverdrawMetrics::didUpload(const WebTransformationMatrix& transformToTarget, const gfx::Rect& uploadRect, const gfx::Rect& opaqueRect)
+void OverdrawMetrics::didUpload(const gfx::Transform& transformToTarget, const gfx::Rect& uploadRect, const gfx::Rect& opaqueRect)
{
if (!m_recordMetricsForFrame)
return;
@@ -99,7 +97,7 @@ void OverdrawMetrics::didUseRenderSurfaceTextureMemoryBytes(size_t renderSurface
m_renderSurfaceTextureUseBytes += renderSurfaceUseBytes;
}
-void OverdrawMetrics::didCullForDrawing(const WebTransformationMatrix& transformToTarget, const gfx::Rect& beforeCullRect, const gfx::Rect& afterCullRect)
+void OverdrawMetrics::didCullForDrawing(const gfx::Transform& transformToTarget, const gfx::Rect& beforeCullRect, const gfx::Rect& afterCullRect)
{
if (!m_recordMetricsForFrame)
return;
@@ -110,7 +108,7 @@ void OverdrawMetrics::didCullForDrawing(const WebTransformationMatrix& transform
m_pixelsCulledForDrawing += beforeCullArea - afterCullArea;
}
-void OverdrawMetrics::didDraw(const WebTransformationMatrix& transformToTarget, const gfx::Rect& afterCullRect, const gfx::Rect& opaqueRect)
+void OverdrawMetrics::didDraw(const gfx::Transform& transformToTarget, const gfx::Rect& afterCullRect, const gfx::Rect& opaqueRect)
{
if (!m_recordMetricsForFrame)
return;
« no previous file with comments | « cc/overdraw_metrics.h ('k') | cc/quad_culler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698