| 1291 | |
| 1292 | |
| 1293 | public void quadraticVertex(float cx, float cy, |
| 1294 | float x3, float y3) { |
| 1295 | if (vertices == null) { |
| 1296 | vertices = new float[10][]; |
| 1297 | } else if (vertexCount + 1 >= vertices.length) { |
| 1298 | vertices = (float[][]) PApplet.expand(vertices); |
| 1299 | } |
| 1300 | vertices[vertexCount++] = new float[] { cx, cy }; |
| 1301 | vertices[vertexCount++] = new float[] { x3, y3 }; |
| 1302 | |
| 1303 | // vertexCodes must be allocated because a vertex() call is required |
| 1304 | if (vertexCodes.length == vertexCodeCount) { |
| 1305 | vertexCodes = PApplet.expand(vertexCodes); |
| 1306 | } |
| 1307 | vertexCodes[vertexCodeCount++] = QUADRATIC_VERTEX; |
| 1308 | |
| 1309 | if (x3 > width) { |
| 1310 | width = x3; |
| 1311 | } |
| 1312 | if (y3 > height) { |
| 1313 | height = y3; |
| 1314 | } |
| 1315 | } |
| 1316 | |
| 1317 | |
| 1318 | public void quadraticVertex(float cx, float cy, float cz, |