mirror of
https://github.com/processing/processing4.git
synced 2026-02-03 21:59:20 +01:00
Correct logic of begin/end contours in PShape. Fixes issue #1417
This commit is contained in:
@@ -350,6 +350,10 @@ public class PShapeOpenGL extends PShape {
|
||||
|
||||
normalMode = NORMAL_MODE_AUTO;
|
||||
|
||||
// To make sure that the first vertex is marked as a break.
|
||||
// Same behavior as in the immediate mode.
|
||||
breakShape = true;
|
||||
|
||||
if (family == GROUP) {
|
||||
// GROUP shapes are always marked as ended.
|
||||
shapeEnded = true;
|
||||
@@ -895,6 +899,7 @@ public class PShapeOpenGL extends PShape {
|
||||
return;
|
||||
}
|
||||
openContour = true;
|
||||
breakShape = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -910,7 +915,6 @@ public class PShapeOpenGL extends PShape {
|
||||
return;
|
||||
}
|
||||
openContour = false;
|
||||
breakShape = true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user