how to decide whether a linear approximation to nonlinear geometry or field should be subdivided
More...
|
virtual const char * | GetClassName () |
|
virtual int | IsA (const char *type) |
|
virtual void | PrintSelf (ostream &os, vtkIndent indent) |
|
virtual bool | EvaluateEdge (const double *p0, double *p1, const double *p2, int field_start)=0 |
|
virtual int | PassField (int sourceId, int sourceSize, vtkStreamingTessellator *t) |
|
virtual void | ResetFieldList () |
|
virtual bool | DontPassField (int sourceId, vtkStreamingTessellator *t) |
|
const int * | GetFieldIds () const |
|
const int * | GetFieldOffsets () const |
|
int | GetOutputField (int fieldId) const |
|
int | GetNumberOfFields () const |
|
virtual void | DebugOn () |
|
virtual void | DebugOff () |
|
unsigned char | GetDebug () |
|
void | SetDebug (unsigned char debugFlag) |
|
virtual void | Modified () |
|
virtual unsigned long | GetMTime () |
|
unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
|
unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
|
vtkCommand * | GetCommand (unsigned long tag) |
|
void | RemoveObserver (vtkCommand *) |
|
void | RemoveObservers (unsigned long event, vtkCommand *) |
|
void | RemoveObservers (const char *event, vtkCommand *) |
|
int | HasObserver (unsigned long event, vtkCommand *) |
|
int | HasObserver (const char *event, vtkCommand *) |
|
void | RemoveObserver (unsigned long tag) |
|
void | RemoveObservers (unsigned long event) |
|
void | RemoveObservers (const char *event) |
|
void | RemoveAllObservers () |
|
int | HasObserver (unsigned long event) |
|
int | HasObserver (const char *event) |
|
template<class U , class T > |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
|
template<class U , class T > |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
|
int | InvokeEvent (unsigned long event, void *callData) |
|
int | InvokeEvent (const char *event, void *callData) |
|
int | InvokeEvent (unsigned long event) |
|
int | InvokeEvent (const char *event) |
|
const char * | GetClassName () const |
|
virtual void | Delete () |
|
virtual void | FastDelete () |
|
void | Print (ostream &os) |
|
virtual void | Register (vtkObjectBase *o) |
|
virtual void | UnRegister (vtkObjectBase *o) |
|
void | SetReferenceCount (int) |
|
void | PrintRevisions (ostream &os) |
|
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
|
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
|
int | GetReferenceCount () |
|
|
| vtkEdgeSubdivisionCriterion () |
|
virtual | ~vtkEdgeSubdivisionCriterion () |
|
bool | ViewDependentEval (const double *p0, double *p1, double *p1_actual, const double *p2, int field_start, vtkMatrix4x4 *viewtrans, const double *pixelSize, double allowableChordErr) const |
|
bool | FixedFieldErrorEval (const double *p0, double *p1, double *p1_actual, const double *p2, int field_start, int field_criteria, double *allowableFieldErr) const |
|
| vtkObject () |
|
virtual | ~vtkObject () |
|
virtual void | RegisterInternal (vtkObjectBase *, int check) |
|
virtual void | UnRegisterInternal (vtkObjectBase *, int check) |
|
void | InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=NULL) |
|
void | InternalReleaseFocus () |
|
| vtkObjectBase () |
|
virtual | ~vtkObjectBase () |
|
virtual void | CollectRevisions (ostream &os) |
|
virtual void | ReportReferences (vtkGarbageCollector *) |
|
| vtkObjectBase (const vtkObjectBase &) |
|
void | operator= (const vtkObjectBase &) |
|
how to decide whether a linear approximation to nonlinear geometry or field should be subdivided
$Date$ $Revision$
Descendants of this abstract class are used to decide whether a piecewise linear approximation (triangles, lines, ... ) to some nonlinear geometry should be subdivided. This decision may be based on an absolute error metric (chord error) or on some view-dependent metric (chord error compared to device resolution) or on some abstract metric (color error). Or anything else, really. Just so long as you implement the EvaluateEdge member, all will be well.
- See Also
- vtkDataSetSubdivisionAlgorithm vtkStreamingTessellator
- Tests:
- vtkEdgeSubdivisionCriterion (Tests)
Definition at line 46 of file vtkEdgeSubdivisionCriterion.h.
bool vtkEdgeSubdivisionCriterion::ViewDependentEval |
( |
const double * |
p0, |
|
|
double * |
p1, |
|
|
double * |
p1_actual, |
|
|
const double * |
p2, |
|
|
int |
field_start, |
|
|
vtkMatrix4x4 * |
viewtrans, |
|
|
const double * |
pixelSize, |
|
|
double |
allowableChordErr |
|
) |
| const |
|
protected |
Perform the core logic for a view-dependent subdivision. Returns
true if subdivision should occur, false otherwise. This is to be used by subclasses once the mesh-specific evaluation routines have been called to get the actual (as opposed to linearly interpolated) midpoint coordinates. Currently, this handles only geometry, but could conceivably test scalar fields as well.
- Parameters
-
p0 | is the first endpoint of the edge |
p1 | is the linearly interpolated midpoint of the edge |
p1_actual | is the actual midpoint of the edge |
p2 | is the second endpoint of the edge |
field_start | is the offset into the above arrays indicating where the scalar field values start (when isosurfacing, the embedding dimension may be smaller than the number of parametric coordinates). |
viewtrans | is the viewing transform (from model to screen coordinates). Applying this transform to p0, p1, etc., should yield screen-space coordinates. |
pixelSize | is the width and height of a pixel in screen space coordinates. |
allowableChordErr | is the maximum allowable distance between p1 and p1_actual, in multiples of pixelSize, before subdivision will occur. |