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

Unified Diff: src/gpu/GrAARectRenderer.cpp

Issue 417113002: round and bevel hairline rects show the same as miter hairline rects (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: update comment Created 6 years, 5 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrAARectRenderer.cpp
diff --git a/src/gpu/GrAARectRenderer.cpp b/src/gpu/GrAARectRenderer.cpp
index 59e9b6f810d70b565057c82e8caf8daab4c2b0c4..0cea0ddd88117a77ec9ec23a99b7a32baf08eefd 100644
--- a/src/gpu/GrAARectRenderer.cpp
+++ b/src/gpu/GrAARectRenderer.cpp
@@ -759,8 +759,10 @@ void GrAARectRenderer::strokeAARect(GrGpu* gpu,
devOutside.outset(rx, ry);
bool miterStroke = true;
+ // For hairlines, make bevel and round joins appear the same as mitered ones.
// small miter limit means right angles show bevel...
- if (stroke.getJoin() != SkPaint::kMiter_Join || stroke.getMiter() < SK_ScalarSqrt2) {
+ if ((width > 0) && (stroke.getJoin() != SkPaint::kMiter_Join ||
+ stroke.getMiter() < SK_ScalarSqrt2)) {
miterStroke = false;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698