[vtkusers] vtkHardwareSelector blacking out window with QVTKOpenGLWidget

King, Franklin fking1 at bwh.harvard.edu
Wed Jul 18 15:30:33 EDT 2018


I've attached the small example. It's identical to the working ExtractVisibleCells example except for the small addition of the QVTKOpenGLWidget and using its render window rather than having one standalone.


I'm actually using this version of VTK 9 (https://github.com/Slicer/VTK/tree/slicer-v9.0.0-2018-04-17-10e8cdc) which seems to date back to April 2018.


Thanks,


Franklin

________________________________
From: Ken Martin <ken.martin at kitware.com>
Sent: Wednesday, July 18, 2018 2:48:44 PM
To: King, Franklin
Cc: vtkusers at public.kitware.com
Subject: Re: [vtkusers] vtkHardwareSelector blacking out window with QVTKOpenGLWidget


        External Email - Use Caution

How recent is the VTK you tried with, there were significant changes made to this code in the past week?  Can you zip up a small example I could build and try?

On Wed, Jul 18, 2018 at 1:31 PM, King, Franklin <fking1 at bwh.harvard.edu<mailto:fking1 at bwh.harvard.edu>> wrote:

Hi,


I've been attempting to run what is essentially this example of extracting visible cells using vtkHardwareSelector (https://www.vtk.org/Wiki/VTK/Examples/Cxx/Filtering/ExtractVisibleCells) but with the render window displayed within a QVTKOpenGLWidge instead.


Doing so, however, results in the entire window failing to render and appearing black upon this line:

vtkSelection* selection = selector->Select();

I've tried disabling multisampling with both QSurfaceFormat and vtkRenderWindow to no avail.


The window does, however, briefly render correctly (and the selection appearing successful) upon resizing events. Curiously, with a debug build it also renders correctly upon calling Select() again.


I am using VTK 9 with Qt 5.10.1, and I've confirmed that there is no issue when implementing with just a vtkRenderWindow or using QVTKWidget in VTK 7. Any idea as to what is going wrong?


Thanks,


Franklin

The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.

_______________________________________________
Powered by www.kitware.com<http://www.kitware.com>

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
https://public.kitware.com/mailman/listinfo/vtkusers




--
Ken Martin PhD
Distinguished Engineer
Kitware Inc.
101 East Weaver Street
Carrboro, North Carolina
27510 USA

This communication, including all attachments, contains confidential and legally privileged information, and it is intended only for the use of the addressee.  Access to this email by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying, distribution or any action taken in reliance on it is prohibited and may be unlawful. If you received this communication in error please notify us immediately and destroy the original message.  Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180718/3d9eae21/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ExtractVisibleCells.zip
Type: application/x-zip-compressed
Size: 2152 bytes
Desc: ExtractVisibleCells.zip
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180718/3d9eae21/attachment.bin>


More information about the vtkusers mailing list