[vtkusers] [VTK 6.2] Issue with QVTKWidget on Qt5

Júlio Hoffimann julio.hoffimann at gmail.com
Sun Nov 30 18:46:33 EST 2014


Nevermind, problem solved. I needed to add a vtkRenderer to the
vtkRenderWindow returned by widget->GetRenderWindow().

The question about QVTKWidget2 remains open.

-Júlio



2014-11-30 15:29 GMT-08:00 Júlio Hoffimann <julio.hoffimann at gmail.com>:

> Dear all,
>
> Consider the following code:
>
> #include <QApplication>#include <QMainWindow>#include <vtkSmartPointer.h>#include <QVTKWidget.h>
> int main( int argc, char **argv ){
>   QApplication app(argc,argv);
>   QMainWindow *mainWindow = new QMainWindow;
>
>   QVTKWidget *widget = new QVTKWidget;
>   mainWindow->setCentralWidget(widget);
>
>   mainWindow->show();
>   return app.exec();}
>
> If I compile it on my Linux box with Qt5 and VTK 6.2, I get a black window
> with strange effects whenever I try to resize it. It may be a graphics card
> issue, can you reproduce it?
>
> Also, what is the difference between QVTKWidget and QVTKWidget2? I wasn't
> able to find them in the Doxygen online reference.
>
> Best,
> Júlio.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20141130/0e6af9a8/attachment.html>


More information about the vtkusers mailing list