VTK
|
Superclass for gradient estimation. More...
#include <vtkEncodedGradientEstimator.h>
Public Types | |
typedef vtkObject | Superclass |
![]() | |
typedef vtkObjectBase | Superclass |
Public Member Functions | |
virtual int | IsA (const char *type) |
vtkEncodedGradientEstimator * | NewInstance () const |
void | PrintSelf (ostream &os, vtkIndent indent) |
void | Update (void) |
unsigned short * | GetEncodedNormals (void) |
unsigned char * | GetGradientMagnitudes (void) |
virtual int | GetUseCylinderClip () |
int * | GetCircleLimits () |
virtual int * | GetInputSize () |
virtual void | GetInputSize (int data[3]) |
virtual float * | GetInputAspect () |
virtual void | GetInputAspect (float data[3]) |
virtual void | SetInputData (vtkImageData *) |
virtual vtkImageData * | GetInputData () |
virtual void | SetGradientMagnitudeScale (float) |
virtual float | GetGradientMagnitudeScale () |
virtual void | SetGradientMagnitudeBias (float) |
virtual float | GetGradientMagnitudeBias () |
virtual void | SetBoundsClip (int) |
virtual int | GetBoundsClip () |
virtual void | BoundsClipOn () |
virtual void | BoundsClipOff () |
virtual void | SetBounds (int, int, int, int, int, int) |
virtual void | SetBounds (int[6]) |
virtual int * | GetBounds () |
virtual void | GetBounds (int data[6]) |
int | GetEncodedNormalIndex (vtkIdType xyz_index) |
int | GetEncodedNormalIndex (int x_index, int y_index, int z_index) |
virtual void | SetNumberOfThreads (int) |
virtual int | GetNumberOfThreads () |
void | SetDirectionEncoder (vtkDirectionEncoder *direnc) |
virtual vtkDirectionEncoder * | GetDirectionEncoder () |
virtual void | SetComputeGradientMagnitudes (int) |
virtual int | GetComputeGradientMagnitudes () |
virtual void | ComputeGradientMagnitudesOn () |
virtual void | ComputeGradientMagnitudesOff () |
virtual void | SetCylinderClip (int) |
virtual int | GetCylinderClip () |
virtual void | CylinderClipOn () |
virtual void | CylinderClipOff () |
virtual float | GetLastUpdateTimeInSeconds () |
virtual float | GetLastUpdateTimeInCPUSeconds () |
void | SetZeroNormalThreshold (float v) |
virtual float | GetZeroNormalThreshold () |
virtual void | SetZeroPad (int) |
virtual int | GetZeroPad () |
virtual void | ZeroPadOn () |
virtual void | ZeroPadOff () |
![]() | |
vtkObject * | NewInstance () const |
virtual void | DebugOn () |
virtual void | DebugOff () |
bool | GetDebug () |
void | SetDebug (bool 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) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, bool(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 &) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
int | GetReferenceCount () |
Static Public Member Functions | |
static int | IsTypeOf (const char *type) |
static vtkEncodedGradientEstimator * | SafeDownCast (vtkObjectBase *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkObject * | SafeDownCast (vtkObjectBase *o) |
static vtkObject * | New () |
static void | BreakOnError () |
static void | SetGlobalWarningDisplay (int val) |
static void | GlobalWarningDisplayOn () |
static void | GlobalWarningDisplayOff () |
static int | GetGlobalWarningDisplay () |
![]() | |
static int | IsTypeOf (const char *name) |
static vtkObjectBase * | New () |
Public Attributes | |
vtkImageData * | InputData |
unsigned short * | EncodedNormals |
int | EncodedNormalsSize [3] |
unsigned char * | GradientMagnitudes |
vtkTimeStamp | BuildTime |
Protected Member Functions | |
virtual vtkObjectBase * | NewInstanceInternal () const |
vtkEncodedGradientEstimator () | |
~vtkEncodedGradientEstimator () | |
virtual void | ReportReferences (vtkGarbageCollector *) |
virtual void | UpdateNormals (void)=0 |
void | ComputeCircleLimits (int size) |
![]() | |
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 &) |
vtkObjectBase (const vtkObjectBase &) | |
void | operator= (const vtkObjectBase &) |
Protected Attributes | |
int | NumberOfThreads |
vtkMultiThreader * | Threader |
vtkDirectionEncoder * | DirectionEncoder |
float | GradientMagnitudeScale |
float | GradientMagnitudeBias |
float | LastUpdateTimeInSeconds |
float | LastUpdateTimeInCPUSeconds |
float | ZeroNormalThreshold |
int | CylinderClip |
int * | CircleLimits |
int | CircleLimitsSize |
int | UseCylinderClip |
int | BoundsClip |
int | Bounds [6] |
int | InputSize [3] |
float | InputAspect [3] |
int | ComputeGradientMagnitudes |
int | ZeroPad |
![]() | |
bool | Debug |
vtkTimeStamp | MTime |
vtkSubjectHelper * | SubjectHelper |
![]() | |
vtkAtomicInt32 | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
Superclass for gradient estimation.
vtkEncodedGradientEstimator is an abstract superclass for gradient estimation. It takes a scalar input of vtkImageData, computes a gradient value for every point, and encodes this value into a three byte value (2 for direction, 1 for magnitude) using the vtkDirectionEncoder. The direction encoder is defaulted to a vtkRecursiveSphereDirectionEncoder, but can be overridden with the SetDirectionEncoder method. The scale and the bias values for the gradient magnitude are used to convert it into a one byte value according to v = m*scale + bias where m is the magnitude and v is the resulting one byte value.
Definition at line 43 of file vtkEncodedGradientEstimator.h.
Definition at line 46 of file vtkEncodedGradientEstimator.h.
|
protected |
|
protected |
|
static |
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkObject.
Reimplemented in vtkFiniteDifferenceGradientEstimator.
|
static |
|
protectedvirtual |
Reimplemented from vtkObject.
Reimplemented in vtkFiniteDifferenceGradientEstimator.
vtkEncodedGradientEstimator* vtkEncodedGradientEstimator::NewInstance | ( | ) | const |
|
virtual |
Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from vtkObject.
Reimplemented in vtkFiniteDifferenceGradientEstimator.
|
virtual |
Set/Get the scalar input for which the normals will be calculated. Note that this call does not setup a pipeline connection. vtkEncodedGradientEstimator is not an algorithm and does not update its input. If you are directly using this class, you may need to manually update the algorithm that produces this data object.
|
virtual |
Set/Get the scalar input for which the normals will be calculated. Note that this call does not setup a pipeline connection. vtkEncodedGradientEstimator is not an algorithm and does not update its input. If you are directly using this class, you may need to manually update the algorithm that produces this data object.
|
virtual |
Set/Get the scale and bias for the gradient magnitude
|
virtual |
Set/Get the scale and bias for the gradient magnitude
|
virtual |
Set/Get the scale and bias for the gradient magnitude
|
virtual |
Set/Get the scale and bias for the gradient magnitude
|
virtual |
Turn on / off the bounding of the normal computation by the this->Bounds bounding box
|
virtual |
Turn on / off the bounding of the normal computation by the this->Bounds bounding box
|
virtual |
Turn on / off the bounding of the normal computation by the this->Bounds bounding box
|
virtual |
Turn on / off the bounding of the normal computation by the this->Bounds bounding box
Set / Get the bounds of the computation (used if this->ComputationBounds is 1.) The bounds are specified xmin, xmax, ymin, ymax, zmin, zmax.
|
virtual |
Set / Get the bounds of the computation (used if this->ComputationBounds is 1.) The bounds are specified xmin, xmax, ymin, ymax, zmin, zmax.
|
virtual |
Set / Get the bounds of the computation (used if this->ComputationBounds is 1.) The bounds are specified xmin, xmax, ymin, ymax, zmin, zmax.
|
virtual |
Set / Get the bounds of the computation (used if this->ComputationBounds is 1.) The bounds are specified xmin, xmax, ymin, ymax, zmin, zmax.
void vtkEncodedGradientEstimator::Update | ( | void | ) |
Recompute the encoded normals and gradient magnitudes.
unsigned short* vtkEncodedGradientEstimator::GetEncodedNormals | ( | void | ) |
Get the encoded normals.
Get the encoded normal at an x,y,z location in the volume
Get the encoded normal at an x,y,z location in the volume
unsigned char* vtkEncodedGradientEstimator::GetGradientMagnitudes | ( | void | ) |
Get the gradient magnitudes
|
virtual |
Get/Set the number of threads to create when encoding normals This defaults to the number of available processors on the machine
|
virtual |
Get/Set the number of threads to create when encoding normals This defaults to the number of available processors on the machine
void vtkEncodedGradientEstimator::SetDirectionEncoder | ( | vtkDirectionEncoder * | direnc | ) |
Set / Get the direction encoder used to encode normal directions to fit within two bytes
|
virtual |
Set / Get the direction encoder used to encode normal directions to fit within two bytes
|
virtual |
If you don't want to compute gradient magnitudes (but you do want normals for shading) this can be used. Be careful - if if you a non-constant gradient magnitude transfer function and you turn this on, it may crash
|
virtual |
If you don't want to compute gradient magnitudes (but you do want normals for shading) this can be used. Be careful - if if you a non-constant gradient magnitude transfer function and you turn this on, it may crash
|
virtual |
If you don't want to compute gradient magnitudes (but you do want normals for shading) this can be used. Be careful - if if you a non-constant gradient magnitude transfer function and you turn this on, it may crash
|
virtual |
If you don't want to compute gradient magnitudes (but you do want normals for shading) this can be used. Be careful - if if you a non-constant gradient magnitude transfer function and you turn this on, it may crash
|
virtual |
If the data in each slice is only contained within a circle circumscribed within the slice, and the slice is square, then don't compute anything outside the circle. This circle through the slices forms a cylinder.
|
virtual |
If the data in each slice is only contained within a circle circumscribed within the slice, and the slice is square, then don't compute anything outside the circle. This circle through the slices forms a cylinder.
|
virtual |
If the data in each slice is only contained within a circle circumscribed within the slice, and the slice is square, then don't compute anything outside the circle. This circle through the slices forms a cylinder.
|
virtual |
If the data in each slice is only contained within a circle circumscribed within the slice, and the slice is square, then don't compute anything outside the circle. This circle through the slices forms a cylinder.
|
virtual |
Get the time required for the last update in seconds or cpu seconds
|
virtual |
Get the time required for the last update in seconds or cpu seconds
|
virtual |
|
inline |
Definition at line 139 of file vtkEncodedGradientEstimator.h.
void vtkEncodedGradientEstimator::SetZeroNormalThreshold | ( | float | v | ) |
Set / Get the ZeroNormalThreshold - this defines the minimum magnitude of a gradient that is considered sufficient to define a direction. Gradients with magnitudes at or less than this value are given a "zero normal" index. These are handled specially in the shader, and you can set the intensity of light for these zero normals in the gradient shader.
|
virtual |
Set / Get the ZeroNormalThreshold - this defines the minimum magnitude of a gradient that is considered sufficient to define a direction. Gradients with magnitudes at or less than this value are given a "zero normal" index. These are handled specially in the shader, and you can set the intensity of light for these zero normals in the gradient shader.
|
virtual |
Assume that the data value outside the volume is zero when computing normals.
|
virtual |
Assume that the data value outside the volume is zero when computing normals.
|
virtual |
Assume that the data value outside the volume is zero when computing normals.
|
virtual |
Assume that the data value outside the volume is zero when computing normals.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
protectedvirtual |
Reimplemented from vtkObjectBase.
|
protectedpure virtual |
Implemented in vtkFiniteDifferenceGradientEstimator.
|
protected |
vtkImageData* vtkEncodedGradientEstimator::InputData |
Definition at line 157 of file vtkEncodedGradientEstimator.h.
unsigned short* vtkEncodedGradientEstimator::EncodedNormals |
Definition at line 170 of file vtkEncodedGradientEstimator.h.
int vtkEncodedGradientEstimator::EncodedNormalsSize[3] |
Definition at line 171 of file vtkEncodedGradientEstimator.h.
unsigned char* vtkEncodedGradientEstimator::GradientMagnitudes |
Definition at line 174 of file vtkEncodedGradientEstimator.h.
vtkTimeStamp vtkEncodedGradientEstimator::BuildTime |
Definition at line 177 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 191 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 193 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 195 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 199 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 200 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 202 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 203 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 205 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 207 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 208 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 209 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 210 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 213 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 214 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 216 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 217 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 219 of file vtkEncodedGradientEstimator.h.
|
protected |
Definition at line 221 of file vtkEncodedGradientEstimator.h.