/** * @return An instance of LineSegment3 that is intended for temporary use in calculations and so forth. Multiple * calls to the method should return instances of this class that are not currently in use. */ public final static LineSegment3 fetchTempInstance() { if (MathConstants.useMathPools) { return LineSegment3.LINESEG3_POOL.fetch(); } else { return new LineSegment3(); } }
/** * @return An instance of Rectangle2 that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static Rectangle2 fetchTempInstance() { if (MathConstants.useMathPools) { return Rectangle2.RECTANGLE_POOL.fetch(); } else { return new Rectangle2(); } }
/** * @return An instance of ColorRGBA that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static ColorRGBA fetchTempInstance() { if (MathConstants.useMathPools) { return ColorRGBA.COLOR_POOL.fetch(); } else { return new ColorRGBA(); } }
/** * @return An instance of Matrix4 that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Matrix4 fetchTempInstance() { if (MathConstants.useMathPools) { return Matrix4.MAT_POOL.fetch(); } else { return new Matrix4(); } }
/** * @return An instance of Ray that is intended for temporary use in calculations and so forth. Multiple calls to the * method should return instances of this class that are not currently in use. */ public final static Ray3 fetchTempInstance() { if (MathConstants.useMathPools) { return Ray3.RAY_POOL.fetch(); } else { return new Ray3(); } }
/** * @return An instance of Matrix3 that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Matrix3 fetchTempInstance() { if (MathConstants.useMathPools) { return Matrix3.MAT_POOL.fetch(); } else { return new Matrix3(); } }
/** * @return An instance of Ring that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Ring fetchTempInstance() { if (MathConstants.useMathPools) { return Ring.RING_POOL.fetch(); } else { return new Ring(); } }
/** * @return An instance of Line3 that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Line3 fetchTempInstance() { if (MathConstants.useMathPools) { return LINE3_POOL.fetch(); } else { return new Line3(); } }
/** * @return An instance of LineSegment3 that is intended for temporary use in calculations and so forth. Multiple * calls to the method should return instances of this class that are not currently in use. */ public final static LineSegment3 fetchTempInstance() { if (MathConstants.useMathPools) { return LineSegment3.LINESEG3_POOL.fetch(); } else { return new LineSegment3(); } }
/** * @return An instance of Transform that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static Transform fetchTempInstance() { if (MathConstants.useMathPools) { return Transform.TRANS_POOL.fetch(); } else { return new Transform(); } }
/** * @return An instance of Plane that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Plane fetchTempInstance() { if (MathConstants.useMathPools) { return Plane.PLANE_POOL.fetch(); } else { return new Plane(); } }
/** * @return An instance of Vector2 that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Vector2 fetchTempInstance() { if (MathConstants.useMathPools) { return Vector2.VEC_POOL.fetch(); } else { return new Vector2(); } }
/** * @return An instance of Rectangle3 that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static Rectangle3 fetchTempInstance() { if (MathConstants.useMathPools) { return Rectangle3.RECTANGLE_POOL.fetch(); } else { return new Rectangle3(); } }
/** * @return An instance of Line3 that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Line3 fetchTempInstance() { if (MathConstants.useMathPools) { return LINE3_POOL.fetch(); } else { return new Line3(); } }
/** * @return An instance of Triangle that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static Triangle fetchTempInstance() { if (MathConstants.useMathPools) { return Triangle.TRI_POOL.fetch(); } else { return new Triangle(); } }
/** * @return An instance of Plane that is intended for temporary use in calculations and so forth. Multiple calls to * the method should return instances of this class that are not currently in use. */ public final static Plane fetchTempInstance() { if (MathConstants.useMathPools) { return Plane.PLANE_POOL.fetch(); } else { return new Plane(); } }
/** * @return An instance of Ray that is intended for temporary use in calculations and so forth. Multiple calls to the * method should return instances of this class that are not currently in use. */ public final static Ray3 fetchTempInstance() { if (MathConstants.useMathPools) { return Ray3.RAY_POOL.fetch(); } else { return new Ray3(); } }
/** * @return An instance of Triangle that is intended for temporary use in calculations and so forth. Multiple calls * to the method should return instances of this class that are not currently in use. */ public final static Triangle fetchTempInstance() { if (MathConstants.useMathPools) { return Triangle.TRI_POOL.fetch(); } else { return new Triangle(); } }
public final static StateStack fetchTempInstance() { if (Constants.useStatePools) { final StateStack s = STATESTACKS_POOL.fetch(); // re-use already allocated stacks for (final Stack<RenderState> stack : s.stacks.values()) { stack.clear(); } return s; } else { return new StateStack(); } }
public final static StateStack fetchTempInstance() { if (Constants.useStatePools) { final StateStack s = STATESTACKS_POOL.fetch(); // re-use already allocated stacks for (final Stack<RenderState> stack : s.stacks.values()) { stack.clear(); } return s; } else { return new StateStack(); } }