--- /dev/null
+# ----------------------------------
+# - BBTKGEditor v 1.4 BBG BlackBox Diagram file
+# - /home/davila/Creatis/C8/creatools_source/creaMaracasVisu/bbtk/bbs/appli/exampleDrawAxisTree3D.bbg
+# ----------------------------------
+
+APP_START
+CATEGORY:<VOID>
+DESCRIPTION:Description ??
+AUTHOR:Author ??
+COMPLEXBOX:FALSE
+COMPLEXINPUTS:0
+BOXES:4
+BOX
+creaMaracasVisu:DrawAxisTree3D:Box00
+ISEXEC:FALSE
+-21.033945:-26.493137:-900.000000
+24.206055:-36.493137:-900.000000
+PORT
+ColourLaw:"2"
+PORT
+LineWidth:"1"
+PORT
+Opacity:"1"
+PORT
+lstIndexs:"6 3 3"
+PORT
+lstPointX:"10 20 30 40 50 60 30 80 90 40 80 90"
+PORT
+lstPointY:"10 30 20 40 60 60 20 50 70 40 40 60"
+PORT
+lstPointZ:"10 20 30 40 50 60 30 45 53 40 80 90"
+FIN_BOX
+BOX
+vtk:LoadHola:Box01
+ISEXEC:FALSE
+-32.915716:74.662477:-900.000000
+2.634284:64.662477:-900.000000
+FIN_BOX
+BOX
+creaMaracasVisu:ViewerNV:Box02
+ISEXEC:TRUE
+-42.870713:32.594587:-900.000000
+20.849287:22.594587:-900.000000
+FIN_BOX
+BOX
+vtk:vtkImageDataPointerRelay:Box03
+ISEXEC:FALSE
+-32.273458:55.394741:-900.000000
+19.901542:45.394741:-900.000000
+FIN_BOX
+CONNECTIONS:4
+CONNECTION
+Box01:Out:Box03:In
+NumberOfControlPoints:0
+CONNECTION
+Box03:Out:Box02:In
+NumberOfControlPoints:0
+CONNECTION
+Box02:Renderer1:Box00:Renderer
+NumberOfControlPoints:0
+CONNECTION
+Box02:BoxChange:Box00:BoxExecute
+NumberOfControlPoints:0
+APP_END
--- /dev/null
+# ----------------------------------
+# - BBTKGEditor v 1.4 BBS BlackBox Script
+# - /home/davila/Creatis/C8/creatools_source/creaMaracasVisu/bbtk/bbs/appli/exampleDrawAxisTree3D.bbs
+# ----------------------------------
+
+# BBTK GEditor Script
+# ----------------------
+
+include std
+include itkvtk
+include creaMaracasVisu
+include vtk
+
+author "Author ??"
+description "Description ??"
+category "<VOID>"
+
+new creaMaracasVisu:DrawAxisTree3D Box00
+ set Box00.ColourLaw "2"
+ set Box00.LineWidth "1"
+ set Box00.Opacity "1"
+ set Box00.lstIndexs "6 3 3"
+ set Box00.lstPointX "10 20 30 40 50 60 30 80 90 40 80 90"
+ set Box00.lstPointY "10 30 20 40 60 60 20 50 70 40 40 60"
+ set Box00.lstPointZ "10 20 30 40 50 60 30 45 53 40 80 90"
+
+new vtk:LoadHola Box01
+
+new creaMaracasVisu:ViewerNV Box02
+
+new vtk:vtkImageDataPointerRelay Box03
+
+
+connect Box01.Out Box03.In
+
+connect Box03.Out Box02.In
+
+connect Box02.Renderer1 Box00.Renderer
+
+connect Box02.BoxChange Box00.BoxExecute
+
+
+
+# Complex input ports
+exec Box02
polydatamapper->SetInput(polydata);
#else
polydatamapper->SetInputData(polydata);
+ polydatamapper->Update();
#endif
vtkactor->SetMapper(polydatamapper);
vtkactor->GetProperty()->SetColor( r,g,b );
} // Law 2 color for each segment
-
if (bbGetInputColourLaw()==3) // color for each point
{
// Setup the colors array
} // Law 3 color for each point
-
vtkactor->GetProperty()->SetLineWidth( bbGetInputLineWidth() );
vtkactor->GetProperty()->SetOpacity( bbGetInputOpacity() );
{
bbGetInputRenderer()->AddActor( vtkactor );
}
+
}
void DrawAxisTree3D::Process()
{
- printf("EED DrawAxisTree3D::Process start \n");
int iGeneral=0;
int iAxis,sizeLstAxis=bbGetInputlstIndexs().size();
int iActor,sizeActors = vecVtkActors.size();
int numPoints;
+
// if (oldLstSize!=sizeLstAxis)
// {
// oldLstSize=sizeLstAxis;
vecVtkPolyDataMaper.clear();
vecVtkActors.clear();
+
for ( iAxis=0 ; iAxis<sizeLstAxis ; iAxis++)
{
numPoints = bbGetInputlstIndexs()[iAxis];
} // if
// } else {// if oldLstSize
+
for (iActor=0 ; iActor<sizeActors; iActor++)
{
vecVtkActors[iActor]->GetProperty()->SetOpacity( bbGetInputOpacity() );
}
// } // if oldLstSize
- printf("EED DrawAxisTree3D::Process end \n");
-
}
void DrawAxisTree3D::bbUserSetDefaultValues()
bbSetInputOpacity(1);
bbSetInputLineWidth(0.5);
bbSetInputColourLaw(1);
+ bbSetInputTransform(NULL);
}