- Polygon p = new Polygon(path, a);
- p.fill(buf, new Paint.SingleColorPaint(fillcolor));
- p.stroke(buf, strokecolor);
+ if (mesh == null) {
+ Log.warn(this, "generating mesh...");
+ mesh = new Mesh(new Polygon(path, Affine.identity()));
+ Log.warn(this, " done generating mesh.");
+ }
+ mesh.fill(buf, a, fillcolor, true, false);
+ mesh.stroke(buf, a, strokecolor);
+ //mesh.fill(buf, a, fillcolor, true, true);