if (floatArray.size < 2 || floatArray.get(floatArray.size - 2) != ip.x || floatArray.get(floatArray.size - 1) != ip.y) { floatArray.add(ip.x); floatArray.add(ip.y); floatArray.add(e.x); floatArray.add(e.y); } else if (Intersector.pointLineSide(ep2, ep1, s) > 0) { Intersector.intersectLines(s, e, ep1, ep2, ip); floatArray.add(ip.x); floatArray.add(ip.y);
/** Returns a new array containing the remaining values. */ public FloatArray toArray () { FloatArray array = new FloatArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns a new array containing the remaining values. */ public FloatArray toArray () { FloatArray array = new FloatArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns a new array containing the remaining values. */ public FloatArray toArray () { FloatArray array = new FloatArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns a new array containing the remaining values. */ public FloatArray toArray () { FloatArray array = new FloatArray(true, map.size); while (hasNext) array.add(next()); return array; } }
xAdvances.add(glyph.fixedWidth ? 0 : -glyph.xoffset * scaleX - padLeft); else xAdvances.add((lastGlyph.xadvance + lastGlyph.getKerning(ch)) * scaleX); lastGlyph = glyph; float lastGlyphWidth = lastGlyph.fixedWidth ? lastGlyph.xadvance * scaleX : (lastGlyph.width + lastGlyph.xoffset) * scaleX - padRight; xAdvances.add(lastGlyphWidth);
xAdvances.add(glyph.fixedWidth ? 0 : -glyph.xoffset * scaleX - padLeft); else xAdvances.add((lastGlyph.xadvance + lastGlyph.getKerning(ch)) * scaleX); lastGlyph = glyph; float lastGlyphWidth = lastGlyph.fixedWidth ? lastGlyph.xadvance * scaleX : (lastGlyph.width + lastGlyph.xoffset) * scaleX - padRight; xAdvances.add(lastGlyphWidth);
void triangulate () { // seed = 4139368480425561099l; // seed = 6559652580366669361l; MathUtils.random.setSeed(seed); int pointCount = 100; points.clear(); for (int i = 0; i < pointCount; i++) { float value; do { value = MathUtils.random(10, 400); } while (points.contains(value)); points.add(value); do { value = MathUtils.random(10, 400); } while (points.contains(value)); points.add(value); } points.add(Gdx.input.getX()); points.add(Gdx.graphics.getHeight() - Gdx.input.getY()); triangles = trianglulator.computeTriangles(points, false); }
renderedSeconds += maxSecondsPerBuffer; renderedSecondsQueue.add(renderedSeconds); boolean filled = false; for (int i = 0; i < bufferCount; i++) {
renderedSeconds += maxSecondsPerBuffer; renderedSecondsQueue.add(renderedSeconds); boolean filled = false; for (int i = 0; i < bufferCount; i++) {
renderedSeconds += maxSecondsPerBuffer; renderedSecondsQueue.add(renderedSeconds); boolean filled = false; for (int i = 0; i < bufferCount; i++) {
renderedSeconds += maxSecondsPerBuffer; renderedSecondsQueue.add(renderedSeconds); boolean filled = false; for (int i = 0; i < bufferCount; i++) {