[vtkusers] VTK Widget inside of QCanvas

Clinton Stimpson clinton at elemtech.com
Wed Mar 21 12:08:09 EDT 2012


On Wednesday, March 21, 2012 09:51:41 am Doug Hoppes wrote:
> Hi all,
> 
>                 So, I've been working with the QVTKWidget for a while and
> things are working great.  Has anyone tried putting it into a QCanvas? 
> The reason is that I want to do some of the slick QOverlays over my vtk
> window.
> 
> Dougie

I don't know that anyone has done it in QCanvas, but that's old stuff.
Qt overlays with QVTKWidget2 and embedding VTK into the Graphics VIew 
Framework has been done (which is the replacement for QCanvas).

Depending on what overlays you are looking for, you could consider using 
QVTKWidget2 without QGraphicsView.

If you need more than that, you can look at the example in  
VTK/Examples/GUI/Qt/GraphicsView.

A older video of that GraphicsView example can be found here.
http://www.kitware.com/InfovisWiki/images/0/02/Qgraphics-vtk-demo.wmv
Some glitches have been fixed after the video was made, and the current example 
code has VTK rendering the background along with 2 VTK views and a web browser 
overlaid on top of that background.

-- 
Clinton Stimpson
Elemental Technologies, Inc
Computational Simulation Software, LLC
www.csimsoft.com



More information about the vtkusers mailing list