Index: src/gpu/GrAtlas.cpp |
diff --git a/src/gpu/GrAtlas.cpp b/src/gpu/GrAtlas.cpp |
index 331f5d92aa25b8008efee5715112e61fb1e3ed83..ea5ad50a39e5d11e5c630ebb6d2f5c4914ab2fdc 100644 |
--- a/src/gpu/GrAtlas.cpp |
+++ b/src/gpu/GrAtlas.cpp |
@@ -10,6 +10,7 @@ |
#include "GrContext.h" |
#include "GrGpu.h" |
#include "GrRectanizer.h" |
+#include "GrTracing.h" |
/////////////////////////////////////////////////////////////////////////////// |
@@ -90,6 +91,7 @@ bool GrPlot::addSubImage(int width, int height, const void* image, |
} else { |
adjust_for_offset(loc, fOffset); |
GrContext* context = fTexture->getContext(); |
+ TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("skia.gpu"), "GrPlot::uploadToTexture"); |
context->writeTexturePixels(fTexture, |
loc->fX, loc->fY, width, height, |
fTexture->config(), image, 0, |
@@ -110,12 +112,13 @@ void GrPlot::uploadToTexture() { |
SkASSERT(fBatchUploads); |
if (fDirty) { |
+ TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("skia.gpu"), "GrPlot::uploadToTexture"); |
SkASSERT(NULL != fTexture); |
GrContext* context = fTexture->getContext(); |
// We pass the flag that does not force a flush. We assume our caller is |
// smart and hasn't referenced the part of the texture we're about to update |
// since the last flush. |
- int rowBytes = fBytesPerPixel*fRects->width(); |
+ size_t rowBytes = fBytesPerPixel*fRects->width(); |
const unsigned char* dataPtr = fPlotData; |
dataPtr += rowBytes*fDirtyRect.fTop; |
dataPtr += fBytesPerPixel*fDirtyRect.fLeft; |