Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit aef86ad

Browse filesBrowse files
committed
Don't use contouring on the path unless necessary
1 parent 7976970 commit aef86ad
Copy full SHA for aef86ad

File tree

Expand file treeCollapse file tree

1 file changed

+7
-4
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-4
lines changed

‎src/_path.h

Copy file name to clipboardExpand all lines: src/_path.h
+7-4Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -233,10 +233,13 @@ inline void points_in_path(PointArray &points,
233233
transformed_path_t trans_path(path, trans);
234234
no_nans_t no_nans_path(trans_path, true, path.has_curves());
235235
curve_t curved_path(no_nans_path);
236-
contour_t contoured_path(curved_path);
237-
contoured_path.width(r);
238-
239-
point_in_path_impl(points, contoured_path, result);
236+
if (r != 0.0) {
237+
contour_t contoured_path(curved_path);
238+
contoured_path.width(r);
239+
point_in_path_impl(points, contoured_path, result);
240+
} else {
241+
point_in_path_impl(points, curved_path, result);
242+
}
240243
}
241244

242245
template <class PathIterator>

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.