Slicer 5.4
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkSlicerCropVolumeLogic.h
Go to the documentation of this file.
1/*=auto=========================================================================
2
3 Portions (c) Copyright 2005 Brigham and Women's Hospital (BWH) All Rights Reserved.
4
5 See COPYRIGHT.txt
6 or http://www.slicer.org/copyright/copyright.txt for details.
7
8 Program: 3D Slicer
9 Module: $RCSfile: vtkSlicerCropVolumeLogic.h,v $
10 Date: $Date: 2006/01/08 04:48:05 $
11 Version: $Revision: 1.45 $
12
13=========================================================================auto=*/
14
15// .NAME vtkSlicerCropVolumeLogic - slicer logic class for volumes manipulation
16// .SECTION Description
17// This class manages the logic associated with reading, saving,
18// and changing propertied of the volumes
19
20
21#ifndef __vtkSlicerCropVolumeLogic_h
22#define __vtkSlicerCropVolumeLogic_h
23
24// Slicer includes
30// vtk includes
31class vtkMatrix4x4;
32// CropVolumes includes
33#include "vtkSlicerCropVolumeModuleLogicExport.h"
35
36
65class VTK_SLICER_CROPVOLUME_MODULE_LOGIC_EXPORT vtkSlicerCropVolumeLogic
67{
68public:
69
72 void PrintSelf(ostream& os, vtkIndent indent) override;
73
76
80 vtkMRMLVolumeNode* outputNode, bool limitToInputExtent=true, double fillValue=0.0);
81
85 int outputExtent[6], bool limitToInputExtent=false);
86
89 bool isotropicResampling, double spacingScale, int interpolationMode, double fillValue);
90
93 bool isotropicResampling, double spacingScale, int outputExtent[6], double outputSpacing[3]);
94
98
100
102
103 void RegisterNodes() override;
104
105protected:
108
109private:
111 void operator=(const vtkSlicerCropVolumeLogic&) = delete;
112
113 class vtkInternal;
114 vtkInternal* Internal;
115};
116
117#endif
118
MRML node for representing a volume (image stack).
Crop a volume to the specified region of interest.
static void SnapROIToVoxelGrid(vtkMRMLCropVolumeParametersNode *parametersNode)
static vtkSlicerCropVolumeLogic * New()
int Apply(vtkMRMLCropVolumeParametersNode *)
Crop input volume using the specified ROI node.
~vtkSlicerCropVolumeLogic() override
static bool GetInterpolatedCropOutputGeometry(vtkMRMLDisplayableNode *roi, vtkMRMLVolumeNode *inputVolume, bool isotropicResampling, double spacingScale, int outputExtent[6], double outputSpacing[3])
Computes output volume geometry for interpolated cropping (without actually cropping the image).
static bool GetVoxelBasedCropOutputExtent(vtkMRMLDisplayableNode *roi, vtkMRMLVolumeNode *inputVolume, int outputExtent[6], bool limitToInputExtent=false)
void RegisterNodes() override
void PrintSelf(ostream &os, vtkIndent indent) override
int CropInterpolated(vtkMRMLDisplayableNode *roi, vtkMRMLVolumeNode *inputVolume, vtkMRMLVolumeNode *outputNode, bool isotropicResampling, double spacingScale, int interpolationMode, double fillValue)
Perform interpolated cropping.
static bool IsROIAlignedWithInputVolume(vtkMRMLCropVolumeParametersNode *parametersNode)
static int CropVoxelBased(vtkMRMLDisplayableNode *roi, vtkMRMLVolumeNode *inputVolume, vtkMRMLVolumeNode *outputNode, bool limitToInputExtent=true, double fillValue=0.0)
static bool FitROIToInputVolume(vtkMRMLCropVolumeParametersNode *parametersNode)