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

Side by Side Diff: src/gpu/GrRectanizer_skyline.cpp

Issue 309683002: Move GrIPoint16 to SkIPoint16 (and remove GrPoint.h) (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Update to ToT Created 6 years, 6 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/gpu/GrRectanizer_skyline.h ('k') | src/gpu/GrTextContext.h » ('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 /* 2 /*
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrRectanizer_skyline.h" 9 #include "GrRectanizer_skyline.h"
10 #include "SkPoint.h"
10 11
11 bool GrRectanizerSkyline::addRect(int width, int height, GrIPoint16* loc) { 12 bool GrRectanizerSkyline::addRect(int width, int height, SkIPoint16* loc) {
12 if ((unsigned)width > (unsigned)this->width() || 13 if ((unsigned)width > (unsigned)this->width() ||
13 (unsigned)height > (unsigned)this->height()) { 14 (unsigned)height > (unsigned)this->height()) {
14 return false; 15 return false;
15 } 16 }
16 17
17 // find position for new rectangle 18 // find position for new rectangle
18 int bestWidth = this->width() + 1; 19 int bestWidth = this->width() + 1;
19 int bestX; 20 int bestX;
20 int bestY = this->height() + 1; 21 int bestY = this->height() + 1;
21 int bestIndex = -1; 22 int bestIndex = -1;
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 --i; 110 --i;
110 } 111 }
111 } 112 }
112 } 113 }
113 114
114 /////////////////////////////////////////////////////////////////////////////// 115 ///////////////////////////////////////////////////////////////////////////////
115 116
116 GrRectanizer* GrRectanizer::Factory(int width, int height) { 117 GrRectanizer* GrRectanizer::Factory(int width, int height) {
117 return SkNEW_ARGS(GrRectanizerSkyline, (width, height)); 118 return SkNEW_ARGS(GrRectanizerSkyline, (width, height));
118 } 119 }
OLDNEW
« no previous file with comments | « src/gpu/GrRectanizer_skyline.h ('k') | src/gpu/GrTextContext.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698