de.jreality.geometry
Interface ParametricSurfaceFactory.Immersion

All Known Implementing Classes:
BeanInspectorExample.Swallowtail, ParametricSurfaceExample.Swallowtail, ParametricSurfaceFactory.DefaultImmersion, SliderExample.HelicoidCatenoid
Enclosing class:
ParametricSurfaceFactory

public static interface ParametricSurfaceFactory.Immersion

Represents a map of two variables into n--dimensional space.


Method Summary
 void evaluate(double u, double v, double[] xyz, int index)
          The implementation of the formula.
 int getDimensionOfAmbientSpace()
          The dimension of the target space.
 boolean isImmutable()
          Mutable immersions are always recalculated when the update method is called; immutable immersions are only recalculated when the parameter domain changes.
 

Method Detail

isImmutable

boolean isImmutable()
Mutable immersions are always recalculated when the update method is called; immutable immersions are only recalculated when the parameter domain changes.


getDimensionOfAmbientSpace

int getDimensionOfAmbientSpace()
The dimension of the target space.


evaluate

void evaluate(double u,
              double v,
              double[] xyz,
              int index)
The implementation of the formula. If in mathematical notation (f1(u,v), ..., fn(u,v)) is your Rn valued map, where n is the dimension of the ambient space. Then your implementation of evaluate should read
                xyz[3*index]=f1(u,v);
                xyz[3*index+1]=f2(u,v);
                   ...
                xyz[3*index+n-1]=fn(u,v);
  

Parameters:
u - coordinate of the requested value
v - coordinate of the requested value
xyz - an array to put the result of the evaluation into
index - at which to put the result into xyz.