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

Unified Diff: src/utils/SkPatchUtils.cpp

Issue 1316123003: Style Change: SkNEW->new; SkDELETE->delete (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-26 (Wednesday) 15:59:00 EDT Created 5 years, 4 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 | « src/utils/SkPatchUtils.h ('k') | src/utils/SkRTConf.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/SkPatchUtils.cpp
diff --git a/src/utils/SkPatchUtils.cpp b/src/utils/SkPatchUtils.cpp
index 08fd4389d3e4636a3fee37bd02083a0c51f7dd41..e9ff906dd24f13a4965042f28235de0ea9ee9b3c 100644
--- a/src/utils/SkPatchUtils.cpp
+++ b/src/utils/SkPatchUtils.cpp
@@ -217,10 +217,10 @@ bool SkPatchUtils::getVertexData(SkPatchUtils::VertexData* data, const SkPoint c
data->fVertexCount = (lodX + 1) * (lodY + 1);
}
data->fIndexCount = lodX * lodY * 6;
-
- data->fPoints = SkNEW_ARRAY(SkPoint, data->fVertexCount);
- data->fIndices = SkNEW_ARRAY(uint16_t, data->fIndexCount);
-
+
+ data->fPoints = new SkPoint[data->fVertexCount];
+ data->fIndices = new uint16_t[data->fIndexCount];
+
// if colors is not null then create array for colors
SkPMColor colorsPM[kNumCorners];
if (colors) {
@@ -228,12 +228,12 @@ bool SkPatchUtils::getVertexData(SkPatchUtils::VertexData* data, const SkPoint c
for (int i = 0; i < kNumCorners; i++) {
colorsPM[i] = SkPreMultiplyColor(colors[i]);
}
- data->fColors = SkNEW_ARRAY(uint32_t, data->fVertexCount);
+ data->fColors = new uint32_t[data->fVertexCount];
}
// if texture coordinates are not null then create array for them
if (texCoords) {
- data->fTexCoords = SkNEW_ARRAY(SkPoint, data->fVertexCount);
+ data->fTexCoords = new SkPoint[data->fVertexCount];
}
SkPoint pts[kNumPtsCubic];
« no previous file with comments | « src/utils/SkPatchUtils.h ('k') | src/utils/SkRTConf.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698