|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthmi.math.Bezier2f
public class Bezier2f
| Field Summary | |
|---|---|
private static float |
EPS
|
private float |
high
|
private float |
low
|
private int |
np
|
private int |
nseg
|
private Bezier1f |
xspline
|
private Bezier1f |
yspline
|
| Constructor Summary | |
|---|---|
Bezier2f(float[] points)
Creates a new Bezier2f object, where the x and y coordinates of the bezier points and control points are specified in a single float array, alternating between x and y coordinates. |
|
Bezier2f(float[][] points,
float[][] controlPoints)
Create a new Bezier curve with interpolated points "points" which is an array of Vec2f elements, that is, every points[i] must be a float[2] array. |
|
Bezier2f(float[] xcoords,
float[] ycoords)
Creates a new Bezier2f object, where the x and y coordinates of the bezier points and control points are specified in two separate float arrays, of equal length. |
|
| Method Summary | |
|---|---|
static Bezier2f |
bezier2fFromPointsVectorsSingleWeights(float[][] points2f,
float[][] vectors2f,
float[] weights)
Like bezier2fFromPointsVectorsWeights, except that the number of weight must be equal to the number of interpolated points. |
static Bezier2f |
bezier2fFromPointsVectorsWeights(float[][] points2f,
float[][] vectors2f,
float[] weights)
Creates a ne Bezier2f object from an array of Vec2f points that are interpolated, an array of Vec2f tangent vectors, and a float array containing weights. |
float[] |
eval(float[] result,
float u)
Evaluates the Bezier curve and puts the result in a float[2] array result, which is also returned as result value. |
float |
evalFX(float x)
Asssuming that our Bezier curve is a functional relation of the form y = f(x) finds the function value f(x) for the specified x, provided x is within the range [ p[0][0] ; p[n-1].[0] ], where n denotes the number of points, and p[0][0] = x value of point 0, etc. |
float |
evalFX(float x,
float low,
float high)
Asssuming that our Bezier curve is a functional relation of the form y = f(x) for parameter values u within the interval [low, high], evalFX(x) finds the function value y = f(x) The x coordinates are allowed to be either monotoneously increasing or decreasing over the specified interval. |
void |
setRange(float low,
float high)
Sets the interpolation range for the eval method: for an u value low we are at the first point, for u= high we are at the last point. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private Bezier1f xspline
private Bezier1f yspline
private float low
private float high
private int np
private int nseg
private static final float EPS
| Constructor Detail |
|---|
public Bezier2f(float[][] points,
float[][] controlPoints)
public Bezier2f(float[] points)
public Bezier2f(float[] xcoords,
float[] ycoords)
| Method Detail |
|---|
public static Bezier2f bezier2fFromPointsVectorsWeights(float[][] points2f,
float[][] vectors2f,
float[] weights)
public static Bezier2f bezier2fFromPointsVectorsSingleWeights(float[][] points2f,
float[][] vectors2f,
float[] weights)
public void setRange(float low,
float high)
public String toString()
toString in class Object
public float[] eval(float[] result,
float u)
public float evalFX(float x)
public float evalFX(float x,
float low,
float high)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||