 |
VTK
9.0.20210118
|
Go to the documentation of this file.
31 #ifndef vtkImageData_h
32 #define vtkImageData_h
34 #include "vtkCommonDataModelModule.h"
89 double pcoords[3],
double* weights)
override;
91 double tol2,
int& subId,
double pcoords[3],
double* weights)
override;
93 double pcoords[3],
double* weights)
override;
115 virtual void SetDimensions(
int i,
int j,
int k);
120 virtual void SetDimensions(
const int dims[3]);
136 virtual
void GetDimensions(
int dims[3]);
137 #if VTK_ID_TYPE_IMPL != VTK_INT
138 virtual void GetDimensions(
vtkIdType dims[3]);
147 virtual int ComputeStructuredCoordinates(
const double x[3],
int ijk[3],
double pcoords[3]);
166 virtual void GetPointGradient(
int i,
int j,
int k,
vtkDataArray* s,
double g[3]);
171 virtual int GetDataDimension();
193 virtual void SetAxisUpdateExtent(
194 int axis,
int min,
int max,
const int* updateExtent,
int* axisUpdateExtent);
195 virtual void GetAxisUpdateExtent(
int axis,
int& min,
int&
max,
const int* updateExtent);
210 virtual void SetExtent(
int extent[6]);
211 virtual void SetExtent(
int x1,
int x2,
int y1,
int y2,
int z1,
int z2);
212 vtkGetVector6Macro(Extent,
int);
221 virtual double GetScalarTypeMin();
223 virtual double GetScalarTypeMax();
231 virtual int GetScalarSize();
243 virtual
void GetIncrements(
vtkIdType inc[3]);
245 virtual
void GetIncrements(
264 virtual
void GetContinuousIncrements(
266 virtual
void GetContinuousIncrements(
274 virtual
void* GetScalarPointerForExtent(
int extent[6]);
275 virtual
void* GetScalarPointer(
int coordinates[3]);
276 virtual
void* GetScalarPointer(
int x,
int y,
int z);
277 virtual
void* GetScalarPointer();
285 virtual
vtkIdType GetScalarIndex(
int coordinates[3]);
286 virtual
vtkIdType GetScalarIndex(
int x,
int y,
int z);
293 virtual
float GetScalarComponentAsFloat(
int x,
int y,
int z,
int component);
294 virtual
void SetScalarComponentFromFloat(
int x,
int y,
int z,
int component,
float v);
295 virtual
double GetScalarComponentAsDouble(
int x,
int y,
int z,
int component);
296 virtual
void SetScalarComponentFromDouble(
int x,
int y,
int z,
int component,
double v);
304 virtual
void AllocateScalars(
int dataType,
int numComponents);
322 virtual
void CopyAndCastFrom(
vtkImageData* inData,
int x0,
int x1,
int y0,
int y1,
int z0,
int z1)
331 this->CopyAndCastFrom(inData, e);
340 void Crop(
const int* updateExtent)
override;
357 vtkGetVector3Macro(Spacing,
double);
358 virtual void SetSpacing(
double i,
double j,
double k);
359 virtual void SetSpacing(
const double ijk[3]);
371 vtkGetVector3Macro(Origin,
double);
372 virtual void SetOrigin(
double i,
double j,
double k);
373 virtual void SetOrigin(
const double ijk[3]);
383 virtual void SetDirectionMatrix(
const double elements[9]);
384 virtual void SetDirectionMatrix(
double e00,
double e01,
double e02,
double e10,
double e11,
385 double e12,
double e20,
double e21,
double e22);
400 virtual void TransformContinuousIndexToPhysicalPoint(
double i,
double j,
double k,
double xyz[3]);
401 virtual void TransformContinuousIndexToPhysicalPoint(
const double ijk[3],
double xyz[3]);
402 virtual void TransformIndexToPhysicalPoint(
int i,
int j,
int k,
double xyz[3]);
403 virtual void TransformIndexToPhysicalPoint(
const int ijk[3],
double xyz[3]);
404 static void TransformContinuousIndexToPhysicalPoint(
double i,
double j,
double k,
405 double const origin[3],
double const spacing[3],
double const direction[9],
double xyz[3]);
420 virtual void TransformPhysicalPointToContinuousIndex(
double x,
double y,
double z,
double ijk[3]);
421 virtual void TransformPhysicalPointToContinuousIndex(
const double xyz[3],
double ijk[3]);
424 static void ComputeIndexToPhysicalMatrix(
425 double const origin[3],
double const spacing[3],
double const direction[9],
double result[16]);
431 virtual void TransformPhysicalNormalToContinuousIndex(
const double xyz[3],
double ijk[3]);
438 virtual void TransformPhysicalPlaneToContinuousIndex(
double const pplane[4],
double iplane[4]);
451 static void SetNumberOfScalarComponents(
int n,
vtkInformation* meta_data);
452 static int GetNumberOfScalarComponents(
vtkInformation* meta_data);
453 static bool HasNumberOfScalarComponents(
vtkInformation* meta_data);
454 int GetNumberOfScalarComponents();
497 void* GetArrayPointer(
vtkDataArray* array,
int coordinates[3]);
523 void ComputeInternalExtent(
int* intExt,
int* tgtExt,
int* bnds);
558 void ComputeIncrements();
561 void ComputeIncrements(
int numberOfComponents);
565 void ComputeIncrements(
vtkIdType inc[3]);
568 void ComputeIncrements(
int numberOfComponents,
vtkIdType inc[3]);
572 void ComputeTransforms();
575 vtkCell* GetCellTemplateForDataDescription();
577 bool GetIJKMinForCellId(
vtkIdType cellId,
int ijkMin[3]);
578 bool GetIJKMaxForIJKMin(
int ijkMin[3],
int ijkMax[3]);
579 void AddPointsToCellTemplate(
vtkCell* cell,
int ijkMin[3],
int ijkMax[3]);
583 void SetDataDescription(
int desc);
641 return dims[0] * dims[1] * dims[2];
virtual vtkIdType GetNumberOfPoints()=0
Determine the number of points composing the dataset.
unsigned long GetActualMemorySize() override
Return the actual size of the data in kibibytes (1024 bytes).
static int GetDataDimension(int dataDescription)
Return the topological dimension of the data (e.g., 0, 1, 2, or 3D).
void ShallowCopy(vtkDataObject *src) override
Shallow and Deep copy.
void GetCellPoints(vtkIdType cellId, vtkIdList *ptIds) override
Topological inquiry to get points defining cell.
vtkMatrix4x4 * IndexToPhysicalMatrix
int GetMaxCellSize() override
Convenience method returns largest cell size in dataset.
vtkTimeStamp ExtentComputeTime
virtual vtkIdType ComputePointId(int ijk[3])
Given a location in structured coordinates (i-j-k), return the point id.
record modification and/or execution time
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int GetExtentType() override
The extent type is a 3D extent.
virtual void CopyInformationFromPipeline(vtkInformation *vtkNotUsed(info))
Copy from the pipeline information to the data object's own information.
static vtkDataSet * GetData(vtkInformation *info)
Retrieve an instance of this class from an information object.
abstract superclass for arrays of numeric data
a cell that represents a 3D point
represent and manipulate 3x3 transformation matrices
virtual vtkIdType FindCell(double x[3], vtkCell *cell, vtkIdType cellId, double tol2, int &subId, double pcoords[3], double *weights)=0
Locate cell based on global coordinate x and tolerance squared.
cell represents a 1D line
vtkMatrix4x4 * PhysicalToIndexMatrix
virtual void ComputeBounds()
Compute the data bounding box from data points.
#define VTK_SIZEHINT(...)
static void GetCellPoints(vtkIdType cellId, vtkIdList *ptIds, int dataDescription, int dim[3])
Get the points defining a cell.
virtual vtkIdType ComputeCellId(int ijk[3])
Given a location in structured coordinates (i-j-k), return the cell id.
vtkIdType FindPoint(double x, double y, double z)
Locate the closest point to the global coordinate x.
virtual vtkIdType FindPoint(double x, double y, double z)
abstract class to specify cell behavior
static void GetPointCells(vtkIdType ptId, vtkIdList *cellIds, int dim[3])
Get the cells using a point.
topologically and geometrically regular array of data
a simple class to control print indentation
represent and manipulate 4x4 transformation matrices
double * GetPoint(vtkIdType ptId) override
Get point coordinates with ptId such that: 0 <= ptId < NumberOfPoints.
virtual void PrepareForNewData()
make the output data ready for new data to be inserted.
void Initialize() override
Restore data object to initial state.
list of point or cell ids
void GetPointCells(vtkIdType ptId, vtkIdList *cellIds) override
Topological inquiry to get cells using point.
vtkIdType GetNumberOfPoints() override
Determine the number of points composing the dataset.
virtual void Crop(const int *updateExtent)
This method crops the data object (if necessary) so that the extent matches the update extent.
virtual void CopyInformationToPipeline(vtkInformation *vtkNotUsed(info))
Copy information from this data object to the pipeline information.
abstract class to specify dataset behavior
virtual double * GetPoint(vtkIdType ptId)=0
Get point coordinates with ptId such that: 0 <= ptId < NumberOfPoints.
a cell that represents an orthogonal quadrilateral
virtual void CopyStructure(vtkDataSet *ds)=0
Copy the geometric and topological structure of an object.
virtual int GetDataDimension()
Return the dimensionality of the data.
provides thread-safe access to cells
vtkMatrix3x3 * DirectionMatrix
virtual vtkIdType GetNumberOfCells()=0
Determine the number of cells composing the dataset.
int GetDataObjectType() override
Return what type of dataset this is.
static vtkIdType ComputeCellIdForExtent(const int extent[6], const int ijk[3], int dataDescription=VTK_EMPTY)
Given a location in structured coordinates (i-j-k), and the extent of the structured dataset,...
general representation of visualization data
virtual int GetCellType(vtkIdType cellId)=0
Get type of cell with cellId such that: 0 <= cellId < NumberOfCells.
virtual void GetCellBounds(vtkIdType cellId, double bounds[6])
Get the bounds of the cell with cellId such that: 0 <= cellId < NumberOfCells.
const char * GetScalarTypeAsString()
virtual vtkCell * FindAndGetCell(double x[3], vtkCell *cell, vtkIdType cellId, double tol2, int &subId, double pcoords[3], double *weights)
Locate the cell that contains a point and return the cell.
static vtkIdType ComputePointIdForExtent(const int extent[6], const int ijk[3], int dataDescription=VTK_EMPTY)
Given a location in structured coordinates (i-j-k), and the extent of the structured dataset,...
void DeepCopy(vtkDataObject *src) override
static vtkDataObject * New()
virtual vtkCell * GetCell(vtkIdType cellId)=0
Get cell with cellId such that: 0 <= cellId < NumberOfCells.
a cell that represents a 3D orthogonal parallelepiped