views:

156

answers:

1

hello,

I am just learning VTK (and C++ GUI programming) and have hopefully simple question.

The main application launches rendered window at some point in application. Would like to be able for the main thread to continue, while VTK window is displayed. Is there a particular method to launch VTK window as a thread?

My environment is Linux, with boost and pthreads at my disposal. Thanks.

VTK is visualization toolkit, see vtk.org

+1  A: 

You can call vtkRenderWindowInteractor->Start() method. (Get the interactor from your renderer if you didn't create one).

There are tons of examples included with VTK; you should take a look at those! If you don't have them, be sure that when building VTK with cmake, turn on VTK_BUILD_EXAMPLES.

Edit:

You should take a look at the GUI examples since that seems what you are trying to build.

Will