ALBA
|
#include <albaTransformBase.h>
Public Member Functions | |
albaTransformBase () | |
~albaTransformBase () | |
albaTransformBase (const albaTransformBase &) | |
albaAbstractTypeMacro (albaTransformBase, albaReferenceCounted) | |
virtual void | Print (std::ostream &os, const int indent=0) const |
virtual const albaMatrix & | GetMatrix () |
albaMatrix * | GetMatrixPointer () |
void | TransformPoint (const float in[3], float out[3]) |
void | TransformPoint (const double in[3], double out[3]) |
void | TransformNormalAtPoint (const float point[3], const float in[3], float out[3]) |
void | TransformNormalAtPoint (const double point[3], const double in[3], double out[3]) |
void | TransformVectorAtPoint (const float point[3], const float in[3], float out[3]) |
void | TransformVectorAtPoint (const double point[3], const double in[3], double out[3]) |
virtual void | Update () |
void | Modified () |
virtual void | InternalTransformPoint (const double in[3], double out[3]) |
virtual void | InternalTransformPoint (const float in[3], float out[3]) |
virtual unsigned long | GetMTime () |
virtual unsigned long | GetUpdateTime () |
void | SetTimeStamp (albaTimeStamp t) |
albaTimeStamp | GetTimeStamp () |
Public Member Functions inherited from albaReferenceCounted | |
albaReferenceCounted () | |
virtual | ~albaReferenceCounted () |
albaAbstractTypeMacro (albaReferenceCounted, albaObject) | |
virtual void | Delete () |
void | Register (void *obj) |
virtual void | UnRegister (void *obj) |
int | GetReferenceCount () |
void | SetReferenceCount (int) |
Public Member Functions inherited from albaObject | |
albaObject () | |
virtual | ~albaObject () |
virtual void | Delete () |
virtual const char * | GetTypeName () const |
virtual bool | IsA (const char *type_name) const |
virtual bool | IsA (const albaTypeID &type_id) const |
virtual albaObject * | NewObjectInstance () const =0 |
virtual const albaTypeID & | GetTypeId () const |
virtual void | Print (std::ostream &os, const int indent=0) const |
albaObject (const albaObject &c) | |
Public Member Functions inherited from albaEventBroadcaster | |
albaEventBroadcaster (void *owner=NULL) | |
virtual | ~albaEventBroadcaster () |
albaEventBroadcaster (const albaEventBroadcaster &c) | |
void | AddObserver (albaObserver *obj) |
void | AddObserver (albaObserver &obj) |
albaObserverCallback * | AddObserverCallback (void(*f)(void *sender, albaID eid, void *clientdata, void *calldata)) |
bool | RemoveObserver (albaObserver *obj) |
void | RemoveAllObservers () |
bool | IsObserver (albaObserver *obj) |
bool | HasObservers () |
void | GetObservers (std::vector< albaObserver * > &olist) |
void | InvokeEvent (albaEventBase &e) |
void | InvokeEvent (albaEventBase *e) |
void | InvokeEvent (void *sender, albaID id=ID_NO_EVENT, void *data=NULL) |
void | SetChannel (albaID ch) |
albaID | GetChannel () |
virtual void | SetListener (albaObserver *o) |
Public Member Functions inherited from albaEventSender | |
albaEventSender () | |
virtual void | SetListener (albaObserver *o) |
virtual albaObserver * | GetListener () |
virtual bool | HasListener () |
virtual void | InvokeEvent (albaEventBase &e) |
virtual void | InvokeEvent (albaEventBase *e) |
virtual void | InvokeEvent (void *sender, albaID id=ID_NO_EVENT, void *data=NULL) |
Protected Member Functions | |
virtual void | InternalUpdate ()=0 |
Protected Attributes | |
albaAutoPointer< albaMatrix > | m_Matrix |
albaMTime | m_MTime |
albaMTime | m_UpdateTime |
albaMutexLock | m_UpdateMutex |
albaTimeStamp | m_TimeStamp |
Protected Attributes inherited from albaReferenceCounted | |
int | m_ReferenceCount |
Protected Attributes inherited from albaObject | |
bool | m_HeapFlag |
Protected Attributes inherited from albaEventBroadcaster | |
albaObserversList | m_Observers |
albaID | m_Channel |
Protected Attributes inherited from albaEventSender | |
albaObserver * | m_Listener |
Additional Inherited Members | |
Static Public Member Functions inherited from albaObject | |
static const char * | GetStaticTypeName () |
static bool | IsStaticType (const char *type_name) |
static bool | IsStaticType (const albaTypeID &type_id) |
static const albaTypeID & | GetStaticTypeId () |
static albaObject * | SafeDownCast (albaObject *o) |
Protected Types inherited from albaEventBroadcaster | |
typedef std::list< albaObserver * > | albaObserversList |
Superclass for Homogeneous transformations.
albaTransformBase is the superclass for ALBA geometric, and currently homogeneous only, transformations. The idea behind a albaTransformBase is the Update() method should always be called to update the output, which is a albaMatrix internally stored.
Definition at line 46 of file albaTransformBase.h.
albaTransformBase::albaTransformBase | ( | ) |
albaTransformBase::~albaTransformBase | ( | ) |
albaTransformBase::albaTransformBase | ( | const albaTransformBase & | ) |
copy constructor
albaTransformBase::albaAbstractTypeMacro | ( | albaTransformBase | , |
albaReferenceCounted | |||
) |
|
virtual |
print debug information for this object
Reimplemented from albaObject.
|
inlinevirtual |
update and return internal transform matrix
Reimplemented in albaMatrixPipe.
Definition at line 59 of file albaTransformBase.h.
Referenced by albaTransform::Concatenate(), albaTransform::GetOrientation(), albaTransform::GetOrientationWXYZ(), albaTransform::GetPosition(), albaTransform::GetVersor(), and albaTransform::PolarDecomp().
|
inline |
return pointer to internal matrix (after updating).
BEWARE: do not change the matrix directly.
Definition at line 64 of file albaTransformBase.h.
|
inline |
Apply the transformation to a coordinate.
You can use the same array to store both the input and output point.
Definition at line 69 of file albaTransformBase.h.
|
inline |
Apply the transformation to a double-precision coordinate.
You can use the same array to store both the input and output point.
Definition at line 75 of file albaTransformBase.h.
void albaTransformBase::TransformNormalAtPoint | ( | const float | point[3], |
const float | in[3], | ||
float | out[3] | ||
) |
Apply the transformation to a normal at the specified vertex.
If the transformation is a vtkLinearTransform, you can use TransformNormal() instead.
void albaTransformBase::TransformNormalAtPoint | ( | const double | point[3], |
const double | in[3], | ||
double | out[3] | ||
) |
Apply the transformation to a normal at the specified vertex.
If the transformation is a vtkLinearTransform, you can use TransformNormal() instead.
void albaTransformBase::TransformVectorAtPoint | ( | const float | point[3], |
const float | in[3], | ||
float | out[3] | ||
) |
Apply the transformation to a vector at the specified vertex.
If the transformation is a vtkLinearTransform, you can use TransformVector() instead.
void albaTransformBase::TransformVectorAtPoint | ( | const double | point[3], |
const double | in[3], | ||
double | out[3] | ||
) |
Apply the transformation to a vector at the specified vertex.
If the transformation is a vtkLinearTransform, you can use TransformVector() instead.
|
virtual |
Update the transform to account for any changes which have been made.
You should not need to call this method yourself, it is called automatically whenever the transform needs an update. For redefining the transform behavior redefine InternalUpdate() function
Reimplemented in albaMatrixPipe.
|
inline |
update modification time stamp for this object
Definition at line 168 of file albaTransformBase.h.
References m_MTime, and albaMTime::Modified().
Referenced by albaCameraTransform::SetFittingMode(), albaCameraTransform::SetFollowOrientation(), albaCameraTransform::SetFollowPosition(), albaGizmoAutoscaleHelper::SetFollowScale(), albaCameraTransform::SetFollowScale(), albaTransform::SetMatrix(), and albaCameraTransform::SetPositionMode().
|
virtual |
This will calculate the transformation without calling Update.
Meant for use only within other VTK classes.
|
virtual |
|
inlinevirtual |
Make another transform of the same type.
Check for self-reference. Return current modification time.
Reimplemented in albaTransformFrame, albaAbsMatrixPipe, albaMatrixPipe, albaCameraTransform, and albaGizmoAutoscaleHelper.
Definition at line 130 of file albaTransformBase.h.
|
inlinevirtual |
return last update time
Definition at line 133 of file albaTransformBase.h.
|
inline |
set the timestamp for the output matrix
Definition at line 136 of file albaTransformBase.h.
References albaEquals().
Referenced by albaTransform::SetMatrix().
|
inline |
Definition at line 138 of file albaTransformBase.h.
|
protectedpure virtual |
Perform any subclass-specific Update.
Implemented in albaTransform, albaTransformFrame, albaAbsMatrixPipe, albaMatrixPipe, albaCameraTransform, and albaGizmoAutoscaleHelper.
|
protected |
internally stored matrix.
Definition at line 149 of file albaTransformBase.h.
|
protected |
|
protected |
We need to record the time of the last update.
Definition at line 151 of file albaTransformBase.h.
|
protected |
we also need to do mutex locking so updates don't collide.
Definition at line 152 of file albaTransformBase.h.
|
protected |
the timestamp to assign to the output matrix (default=0)
Definition at line 154 of file albaTransformBase.h.