[vtkusers] TCL/TK check existance of VTK-object

Kevin Wright krw at viz-solutions.com
Mon Mar 11 19:12:46 EST 2002


>Anybody know the TCL/TK syntax for checking if a vtk-object already exists?

The interaction between Tcl and VTK is done by creating a Tcl command for 
each VTK object created, so if you have an object named renderWindow, you 
check for the existence of a command called "renderWindow" like so:

if {[info commands renderWindow]} == {}} {
   # no object exists
}

Kevin.





More information about the vtkusers mailing list