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 #include "bbcreaVtkPlaneSource.h"
5 #include "bbcreaVtkPackage.h"
6 #include "vtkPlaneSource.h"
7 #include "vtkDataSet.h"
12 BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaVtk,PlaneSource)
13 BBTK_BLACK_BOX_IMPLEMENTATION(PlaneSource,bbtk::AtomicBlackBox);
15 // 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)
17 void PlaneSource::Process()
19 vtkPlaneSource *plane;
20 plane = vtkPlaneSource::New();
34 c[0]=bbGetInputCenter()[0];
35 c[1]=bbGetInputCenter()[1];
36 c[2]=bbGetInputCenter()[2];
38 plane->SetResolution( bbGetInputXResolution(), bbGetInputYResolution() );
39 plane->SetOrigin( p0 );
40 plane->SetPoint1( p1 );
41 plane->SetPoint2( p2 );
43 plane->SetNormal( bbGetInputNormal()[0], bbGetInputNormal()[1], bbGetInputNormal()[2] );
45 plane->SetCenter( c );
47 bbSetOutputPlane( (vtkDataSet*)plane );
48 bbSetOutputPolyData( plane->GetOutput() );
52 // 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)
54 void PlaneSource::bbUserSetDefaultValues()
56 std::vector<double> c;
57 std::vector<double> n;
66 bbSetInputXResolution(100);
67 bbSetInputYResolution(100);
70 // 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)
72 void PlaneSource::bbUserInitializeProcessing()
78 // 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)
80 void PlaneSource::bbUserFinalizeProcessing()
86 // EO namespace bbcreaVtk