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

Side by Side Diff: src/utils/SkPatchUtils.h

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, 3 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 unified diff | Download patch
« no previous file with comments | « src/utils/SkPatchGrid.cpp ('k') | src/utils/SkPatchUtils.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkPatchUtils_DEFINED 8 #ifndef SkPatchUtils_DEFINED
9 #define SkPatchUtils_DEFINED 9 #define SkPatchUtils_DEFINED
10 10
(...skipping 17 matching lines...) Expand all
28 28
29 VertexData() 29 VertexData()
30 : fVertexCount(0) 30 : fVertexCount(0)
31 , fIndexCount(0) 31 , fIndexCount(0)
32 , fPoints(NULL) 32 , fPoints(NULL)
33 , fTexCoords(NULL) 33 , fTexCoords(NULL)
34 , fColors(NULL) 34 , fColors(NULL)
35 , fIndices(NULL) { } 35 , fIndices(NULL) { }
36 36
37 ~VertexData() { 37 ~VertexData() {
38 SkDELETE_ARRAY(fPoints); 38 delete[] fPoints;
39 SkDELETE_ARRAY(fTexCoords); 39 delete[] fTexCoords;
40 SkDELETE_ARRAY(fColors); 40 delete[] fColors;
41 SkDELETE_ARRAY(fIndices); 41 delete[] fIndices;
42 } 42 }
43 }; 43 };
44 44
45 // Enums for control points based on the order specified in the constructor (clockwise). 45 // Enums for control points based on the order specified in the constructor (clockwise).
46 enum CubicCtrlPts { 46 enum CubicCtrlPts {
47 kTopP0_CubicCtrlPts = 0, 47 kTopP0_CubicCtrlPts = 0,
48 kTopP1_CubicCtrlPts = 1, 48 kTopP1_CubicCtrlPts = 1,
49 kTopP2_CubicCtrlPts = 2, 49 kTopP2_CubicCtrlPts = 2,
50 kTopP3_CubicCtrlPts = 3, 50 kTopP3_CubicCtrlPts = 3,
51 51
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 * colors refers to the corner colors that will be bilerp across the patch ( optional parameter) 112 * colors refers to the corner colors that will be bilerp across the patch ( optional parameter)
113 * texCoords refers to the corner texture coordinates that will be bilerp ac ross the patch 113 * texCoords refers to the corner texture coordinates that will be bilerp ac ross the patch
114 (optional parameter) 114 (optional parameter)
115 */ 115 */
116 static bool getVertexData(SkPatchUtils::VertexData* data, const SkPoint cubi cs[12], 116 static bool getVertexData(SkPatchUtils::VertexData* data, const SkPoint cubi cs[12],
117 const SkColor colors[4], const SkPoint texCoords[4 ], 117 const SkColor colors[4], const SkPoint texCoords[4 ],
118 int lodX, int lodY); 118 int lodX, int lodY);
119 }; 119 };
120 120
121 #endif 121 #endif
OLDNEW
« no previous file with comments | « src/utils/SkPatchGrid.cpp ('k') | src/utils/SkPatchUtils.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698