[vtkusers] slow down when use tcl api
novalet at yahoo.com.cn
Thu Apr 10 01:45:50 EDT 2003
yesterday i write a letter about my experience in
using tcl/vtk in MFC program.
But in fact, the problem is nothing to do with the
MFC, because even the simplest c file will have such
Look, below is the simplest tcl interpreter i written
in tcl API.
int app_init(Tcl_Interp *interp);
int main(int argc, char **argv)
Tk_Main(argc, argv, app_init);
int app_init(Tcl_Interp *interp)
if(Tcl_Init(interp) == TCL_ERROR) return TCL_ERROR;
if(Tk_Init(interp) == TCL_ERROR) return TCL_ERROR;
Compile it to a exe called "mytcl.exe", then i use
this simplest tcl interpreter to run the script in
the vtk. for example
you can also exam with other tcl script. The
conclusion is the wish83 run much faster than mytcl.
So the tcl api must be the source to hinder the vtk
I hope the pals on the list help:
(1) exam the same test on a linux platform.
(2) maybe some guru can compare the wish83 code with
the tcl api to find out what's wrong.
My aim is using tcl to organize vtk pipeline in a
c/c++ program, but if this design will slow the
program so much, it would not be a good idea.
But i can't understand why the api have a performance
problem, i guess the wish83 or tclsh83 are built on
the base of such api.
PS my OS is win2k, i have test it on both vc6 and vc7,
both debug and release mode (vc6 has a worse
performance :< )
Remote Scensing Satellite Ground Station
Chinese Academy of Science
Do You Yahoo!?
More information about the vtkusers