VTK  9.3.20240423
vtkMNITransformWriter.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-FileCopyrightText: Copyright (c) 2006 Atamai, Inc.
3// SPDX-License-Identifier: BSD-3-Clause
23#ifndef vtkMNITransformWriter_h
24#define vtkMNITransformWriter_h
25
26#include "vtkAlgorithm.h"
27#include "vtkIOMINCModule.h" // For export macro
28
29VTK_ABI_NAMESPACE_BEGIN
34class vtkCollection;
35
36class VTKIOMINC_EXPORT vtkMNITransformWriter : public vtkAlgorithm
37{
38public:
40
42 void PrintSelf(ostream& os, vtkIndent indent) override;
43
45
51
55 virtual const char* GetFileExtensions() { return ".xfm"; }
56
60 virtual const char* GetDescriptiveName() { return "MNI Transform"; }
61
63
66 virtual void SetTransform(vtkAbstractTransform* transform);
67 virtual vtkAbstractTransform* GetTransform() { return this->Transform; }
69
75 virtual void AddTransform(vtkAbstractTransform* transform);
76
80 virtual int GetNumberOfTransforms();
81
83
86 vtkSetStringMacro(Comments);
87 vtkGetStringMacro(Comments);
89
93 virtual void Write();
94
95protected:
98
99 char* FileName;
102 char* Comments;
103
104 int WriteLinearTransform(ostream& outfile, vtkHomogeneousTransform* transform);
106 int WriteGridTransform(ostream& outfile, vtkGridTransform* transform);
107
108 virtual int WriteTransform(ostream& outfile, vtkAbstractTransform* transform);
109
110 virtual int WriteFile();
111
113 vtkInformation* request, vtkInformationVector** inInfo, vtkInformationVector* outInfo) override;
114
115private:
117 void operator=(const vtkMNITransformWriter&) = delete;
118};
119
120VTK_ABI_NAMESPACE_END
121#endif
superclass for all geometric transformations
Superclass for all sources, filters, and sinks in VTK.
create and manipulate ordered lists of objects
a nonlinear warp transformation
superclass for homogeneous transformations
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
A writer for MNI transformation files.
vtkSetFilePathMacro(FileName)
Set the file name.
virtual int WriteFile()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void AddTransform(vtkAbstractTransform *transform)
Add another transform to the file.
virtual const char * GetDescriptiveName()
Get the name of this file format.
virtual int WriteTransform(ostream &outfile, vtkAbstractTransform *transform)
virtual int GetNumberOfTransforms()
Get the number of transforms that will be written.
virtual const char * GetFileExtensions()
Get the extension for this file format.
vtkTypeBool ProcessRequest(vtkInformation *request, vtkInformationVector **inInfo, vtkInformationVector *outInfo) override
Upstream/Downstream requests form the generalized interface through which executives invoke a algorit...
vtkAbstractTransform * Transform
static vtkMNITransformWriter * New()
vtkGetFilePathMacro(FileName)
Set the file name.
int WriteGridTransform(ostream &outfile, vtkGridTransform *transform)
~vtkMNITransformWriter() override
virtual void Write()
Write the file.
virtual vtkAbstractTransform * GetTransform()
Set the transform.
int WriteThinPlateSplineTransform(ostream &outfile, vtkThinPlateSplineTransform *transform)
int WriteLinearTransform(ostream &outfile, vtkHomogeneousTransform *transform)
virtual void SetTransform(vtkAbstractTransform *transform)
Set the transform.
a nonlinear warp transformation
int vtkTypeBool
Definition vtkABI.h:64