(float x, float y)
| 1361 | |
| 1362 | |
| 1363 | public void vertex(float x, float y) { |
| 1364 | vertexCheck(); |
| 1365 | float[] vertex = vertices[vertexCount]; |
| 1366 | |
| 1367 | curveVertexCount = 0; |
| 1368 | |
| 1369 | vertex[X] = x; |
| 1370 | vertex[Y] = y; |
| 1371 | vertex[Z] = 0; |
| 1372 | |
| 1373 | vertex[EDGE] = edge ? 1 : 0; |
| 1374 | |
| 1375 | // if (fill) { |
| 1376 | // vertex[R] = fillR; |
| 1377 | // vertex[G] = fillG; |
| 1378 | // vertex[B] = fillB; |
| 1379 | // vertex[A] = fillA; |
| 1380 | // } |
| 1381 | boolean textured = textureImage != null; |
| 1382 | if (fill || textured) { |
| 1383 | if (!textured) { |
| 1384 | vertex[R] = fillR; |
| 1385 | vertex[G] = fillG; |
| 1386 | vertex[B] = fillB; |
| 1387 | vertex[A] = fillA; |
| 1388 | } else { |
| 1389 | if (tint) { |
| 1390 | vertex[R] = tintR; |
| 1391 | vertex[G] = tintG; |
| 1392 | vertex[B] = tintB; |
| 1393 | vertex[A] = tintA; |
| 1394 | } else { |
| 1395 | vertex[R] = 1; |
| 1396 | vertex[G] = 1; |
| 1397 | vertex[B] = 1; |
| 1398 | vertex[A] = 1; |
| 1399 | } |
| 1400 | } |
| 1401 | } |
| 1402 | |
| 1403 | if (stroke) { |
| 1404 | vertex[SR] = strokeR; |
| 1405 | vertex[SG] = strokeG; |
| 1406 | vertex[SB] = strokeB; |
| 1407 | vertex[SA] = strokeA; |
| 1408 | vertex[SW] = strokeWeight; |
| 1409 | } |
| 1410 | |
| 1411 | if (textured) { |
| 1412 | vertex[U] = textureU; |
| 1413 | vertex[V] = textureV; |
| 1414 | } |
| 1415 | |
| 1416 | if (autoNormal) { |
| 1417 | float norm2 = normalX * normalX + normalY * normalY + normalZ * normalZ; |
| 1418 | if (norm2 < EPSILON) { |
| 1419 | vertex[HAS_NORMAL] = 0; |
| 1420 | } else { |
no test coverage detected