15 #ifndef __vtkMRMLTransformNode_h 16 #define __vtkMRMLTransformNode_h 21 class vtkAbstractTransform;
22 class vtkGeneralTransform;
38 void PrintSelf(ostream& os, vtkIndent indent)
override;
48 void WriteXML(ostream& of,
int indent)
override;
67 virtual int IsLinear();
71 virtual int IsComposite();
75 virtual vtkAbstractTransform* GetTransformToParent();
80 virtual int GetMatrixTransformToParent(vtkMatrix4x4* matrix);
85 virtual int GetMatrixTransformFromParent(vtkMatrix4x4* matrix);
92 virtual vtkMatrix4x4* GetMatrixTransformToParent();
99 virtual vtkMatrix4x4* GetMatrixTransformFromParent();
103 virtual const char* GetTransformToParentInfo();
107 virtual vtkAbstractTransform* GetTransformFromParent();
111 virtual const char* GetTransformFromParentInfo();
115 int IsTransformToWorldLinear();
124 void GetTransformToWorld(vtkGeneralTransform* transformToWorld);
129 void GetTransformFromWorld(vtkGeneralTransform* transformToWorld);
135 vtkGeneralTransform* transformToNode);
141 vtkGeneralTransform* transformFromNode);
153 virtual int GetMatrixTransformToWorld(vtkMatrix4x4* transformToWorld);
159 virtual int GetMatrixTransformFromWorld(vtkMatrix4x4* transformFromWorld);
166 vtkMatrix4x4* transformToNode);
173 vtkMatrix4x4* transformFromNode);
209 virtual int SetMatrixTransformToParent(vtkMatrix4x4 *matrix);
214 virtual int SetMatrixTransformFromParent(vtkMatrix4x4 *matrix);
231 virtual int SetAndObserveMatrixTransformToParent(vtkMatrix4x4 *matrix);
237 virtual int SetAndObserveMatrixTransformFromParent(vtkMatrix4x4 *matrix);
270 vtkGetMacro(ReadAsTransformToParent,
int);
271 vtkSetMacro(ReadAsTransformToParent,
int);
272 vtkBooleanMacro(ReadAsTransformToParent,
int);
290 vtkAbstractTransform* GetTransformToParentAs(
const char* transformType,
bool logErrorIfFails =
true,
bool modifiableOnly =
false);
297 vtkAbstractTransform* GetTransformFromParentAs(
const char* transformType,
bool logErrorIfFails =
true,
bool modifiableOnly =
false);
304 void SetAndObserveTransformToParent(vtkAbstractTransform *transform);
311 void SetAndObserveTransformFromParent(vtkAbstractTransform *transform);
321 static void FlattenGeneralTransform(vtkCollection* outputTransformList, vtkAbstractTransform* inputTransform);
326 static bool AreTransformsEqual(vtkAbstractTransform* transform1, vtkAbstractTransform* transform2);
333 static bool IsGeneralTransformLinear(vtkAbstractTransform* inputTransform, vtkTransform* concatenatedLinearTransform=
nullptr);
339 static bool IsAbstractTransformComputedFromInverse(vtkAbstractTransform* abstractTransform);
345 static int DeepCopyTransform(vtkAbstractTransform* dst, vtkAbstractTransform* src);
354 virtual void InverseName();
357 vtkMTimeType GetTransformToWorldMTime();
364 const char* GetTransformInfo(vtkAbstractTransform* inputTransform);
381 virtual vtkAbstractTransform* GetAbstractTransformAs(vtkAbstractTransform* inputTransform,
const char* transformClassName,
bool logErrorIfFails);
385 virtual void SetAndObserveTransform(vtkAbstractTransform** originalTransformPtr, vtkAbstractTransform** inverseTransformPtr, vtkAbstractTransform *transform);
void ProcessMRMLEvents(vtkObject *, unsigned long, void *) override
alternative method to propagate events generated in Display nodes
void ReadXMLAttributes(const char **atts) override
Read node attributes from XML file
virtual vtkMRMLStorageNode * CreateDefaultStorageNode()
virtual void InvokeCustomModifiedEvent(int eventId, void *callData=nullptr)
This method allows the node to compress events.
virtual bool GetModifiedSinceRead()
virtual void CreateDefaultSequenceDisplayNodes()
void WriteXML(ostream &of, int indent) override
Write this node's information to a MRML file in XML format.
void operator=(const vtkMRMLDisplayableNode &)
virtual vtkMRMLStorageNode * CreateDefaultSequenceStorageNode()
A set of MRML Nodes that supports serialization and undo/redo.
void PrintSelf(ostream &os, vtkIndent indent) override
virtual void CreateDefaultDisplayNodes()
A superclass for other storage nodes.
vtkMRMLNode * CreateNodeInstance() override=0
MRMLNode methods.
vtkMRMLCopyContentMacro(vtkMRMLStorableNode)
void UpdateScene(vtkMRMLScene *scene) override
Finds the storage node and read the data
Abstract Superclass for all specific types of MRML nodes.