Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash with OpenGL only window trying to create some Qt widget #442

Open
paskino opened this issue Dec 10, 2024 · 0 comments
Open

Crash with OpenGL only window trying to create some Qt widget #442

paskino opened this issue Dec 10, 2024 · 0 comments

Comments

@paskino
Copy link
Collaborator

paskino commented Dec 10, 2024

Potentially, this should be fixed with #440

On the toolbar3d branch I was exploring a dataset then I clicked probably letf or centre click with a modifier. The whole thing crashed with the following error:

>>> v.startRenderLoop()
QWidget: Must construct a QApplication before a QWidget

I did not have any Qt application running, nor should an interaction with the viewer spawn a QWidget.

Code to reproduce (requires a META image file, like https://github.com/TomographicImaging/CIL-Data/raw/refs/heads/main/head.mha), plus (furiously) click.

reader = vtk.MetaImageReader()
reader.SetFileName('myfilename.mha')
reader.Update()

from ccpi.viewer import viewer2D

v = viewer2D()
v.setInputData(reader.GetOutput())
v.startRenderLoop()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant