[vtkusers] Enable sample buffers on QGLWidget-based VTK widget from Python
elvis.stansvik at orexplore.com
Thu Jun 23 10:21:12 EDT 2016
2016-06-23 15:40 GMT+02:00 Sankhesh Jhaveri <sankhesh.jhaveri at kitware.com>:
> According to Qt documentation, QGLWidget is obsolete in Qt 5 and they
> suggest using QOpenGLWidget (which has setFormat API).
Yes, I know, but I've based my class on QVTKRenderWindowInteractor, which
still uses QGLWidget. So I was looking for some alternative way of doing it
Howeve, I've now begun looking into porting my class to QOpenGLWidget,
taking inspiration from QVTKWidget2 and this SO answer:
But I've hit some snags (will make another post about it).
>  http://doc.qt.io/qt-5/qglwidget.html
> On Thu, Jun 23, 2016 at 8:52 AM, Elvis Stansvik <
> elvis.stansvik at orexplore.com> wrote:
>> This is slightly off-topic, but here it goes: I have my own VTKWidget,
>> similar to QVTKRenderWindowInteractor, which is based on QGLWidget. I
>> wanted to enable sample buffers / samples on it, so that lines et.c. drawn
>> by VTK are anti-aliased.
>> I thought I could do
>> glFormat = self.format()
>> but it turns out setFormat is made obsolete in Qt 5, and PyQt does not
>> wrap obsolete methods.
>> Anyone know of some other way of achieving the same thing?
>> Powered by www.kitware.com
>> Visit other Kitware open-source projects at
>> Please keep messages on-topic and check the VTK FAQ at:
>> Search the list archives at: http://markmail.org/search/?q=vtkusers
>> Follow this link to subscribe/unsubscribe:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vtkusers