2 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
4 #ifndef __bbitkvtkGeodesicMeshDeformation_h_INCLUDED__
5 #define __bbitkvtkGeodesicMeshDeformation_h_INCLUDED__
7 #include "bbitkvtk_EXPORT.h"
8 #include "bbtkAtomicBlackBox.h"
11 #include "vtkPolyData.h"
12 #include "itkQuadEdgeMesh.h"
13 #include "itkFastMarchingThresholdStoppingCriterion.h"
14 //#include "itkFastMarchingQuadEdgeMeshFilterBase.h"
15 #include "itkFastMarchingQuadEdgeMeshFilterResultsBase.h"
20 class bbitkvtk_EXPORT GeodesicMeshDeformation
22 public bbtk::AtomicBlackBox
24 BBTK_BLACK_BOX_INTERFACE(GeodesicMeshDeformation,bbtk::AtomicBlackBox);
26 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
28 BBTK_DECLARE_INPUT(Active, bool);
29 BBTK_DECLARE_INPUT(TypeIn, int);
30 BBTK_DECLARE_INPUT(In,vtkPolyData*);
31 BBTK_DECLARE_INPUT(EdgeId, long);
32 BBTK_DECLARE_INPUT(S, double);
33 BBTK_DECLARE_INPUT(Center, std::vector<double>);
34 BBTK_DECLARE_INPUT(Direction, std::vector<double>);
35 //BBTK_DECLARE_OUTPUT(Out,double);
36 BBTK_PROCESS(Process);
39 using MeshType = itk::QuadEdgeMesh<double, 3>;
41 //This is not the FastMarchingQuadEdge filter from ITK, this is a modified version to increase performance in our use
42 using FastMarchingType = itk::FastMarchingQuadEdgeMeshFilterResultsBase<MeshType, MeshType>;
45 std::vector<int> voiIdPoints;
46 std::vector<double> backLstCenter;
47 vtkPolyData *polydata;
48 MeshType::Pointer quadEdgeMesh;
50 FastMarchingType::Pointer fmmFilter;
53 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
57 BBTK_BEGIN_DESCRIBE_BLACK_BOX(GeodesicMeshDeformation,bbtk::AtomicBlackBox);
58 BBTK_NAME("GeodesicMeshDeformation");
59 BBTK_AUTHOR("InfoDev");
60 BBTK_DESCRIPTION("No Description.");
61 BBTK_CATEGORY("empty");
62 BBTK_INPUT(GeodesicMeshDeformation,Active,"(default true) true/false",bool,"");
63 BBTK_INPUT(GeodesicMeshDeformation,TypeIn,"(default 0) 0:Direction 1:Center",int,"");
64 BBTK_INPUT(GeodesicMeshDeformation,In,"vtk PolyData",vtkPolyData*,"");
65 BBTK_INPUT(GeodesicMeshDeformation,EdgeId,"Edge Id",long,"");
66 BBTK_INPUT(GeodesicMeshDeformation,S,"Deformation",double,"");
67 BBTK_INPUT(GeodesicMeshDeformation,Center,"[X,Y,Z]",std::vector<double>,"");
68 BBTK_INPUT(GeodesicMeshDeformation,Direction,"(default [1,0,0]) [X,Y,Z]",std::vector<double>,"");
69 BBTK_END_DESCRIBE_BLACK_BOX(GeodesicMeshDeformation);
71 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
74 // EO namespace bbitkvtk
76 #endif // __bbitkvtkGeodesicMeshDeformation_h_INCLUDED__