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

BackgroundPlotter not workin on Mac with vtk9 #15

Closed
banesullivan opened this issue Jun 9, 2020 · 13 comments
Closed

BackgroundPlotter not workin on Mac with vtk9 #15

banesullivan opened this issue Jun 9, 2020 · 13 comments

Comments

@banesullivan
Copy link
Member

I still cannot get the BackgrounPlotter to work with VTK9.0 on Mac. See pyvista/pyvista#562 (comment)

cc @Leguark, since you all are using the BackgroundPlotter in GemPy, you may want to limit vtk in your setup.py until we get this fixed: vtk<9.0.0

cc @GuillaumeFavelier, are you all seeing this with MNE-Python?

@GuillaumeFavelier
Copy link
Contributor

I know that we have a job on Travis configured with vtk 9.0.0 for MacOS but I'm not 100% sure it runs all the tests, it might skip a lot. We still have to get reports from users on MacOS that did the upgrade to vtk 9.0.0

@GuillaumeFavelier
Copy link
Contributor

To move forward with this one, @banesullivan could you maybe try a very simple example like the default QVTKRenderWidgetConeExample and confirm that everything works fine for you?

I think the priority here is to understand where is the issue.

@larsoner
Copy link
Contributor

Possibly related to initialize/start/show ordering?

https://discourse.vtk.org/t/vtk-9-pyqt-macos-no-rendering/3358/22

@larsoner
Copy link
Contributor

(This thread also explains why macOS rendering worked for me at one point when building the wheels myself, but stopped working once I switched to using the official VTK wheels)

@cbrnr
Copy link

cbrnr commented Jun 15, 2020

FWIW, toggling the "Eye Dome Lighting" setting made a figure change from completely black to actually show the figure correctly.

@banesullivan
Copy link
Member Author

Thanks for the tip, @cbrnr - I will have to look into why that is...


FYI: VTK 9.0.1 fixed this issue for me (see #16 (comment)) but @larsoner is still having trouble?

@larsoner
Copy link
Contributor

I'm still having trouble with MNE examples, but it might be something we're doing at our end

@larsoner
Copy link
Contributor

larsoner commented Jun 29, 2020

Okay I figured out the problem, enable_anti_aliasing gives me a black canvas:

import pyvista as pv
from pyvistaqt import BackgroundPlotter

p = BackgroundPlotter()
p.enable_anti_aliasing()
p.add_mesh(pv.Cone())

@larsoner
Copy link
Contributor

... and also the VTK widget controls we have are only controllable by mouse clicks at 1/2 the correct location, meaning the VTK has some HiDPI problem with its widget controls and clicks...

@cbrnr
Copy link

cbrnr commented Jun 29, 2020

And if you then toggle eyedome lighting, it works!

@larsoner
Copy link
Contributor

The widgets work? Or antialiasing works? Or you need AA off / commented out plus eyedome toggle to see the simple example above?

@cbrnr
Copy link

cbrnr commented Jun 29, 2020

Your example initially looks like this:

Screen Shot 2020-06-29 at 20 59 44

After clicking on View - Toggle Eye Dome Lighting, it looks like this:

Screen Shot 2020-06-29 at 20 59 55

@larsoner
Copy link
Contributor

larsoner commented Apr 5, 2022

I think this was fixed by VTK in https://gitlab.kitware.com/vtk/vtk/-/merge_requests/7420 / 9.1, so we might as well close I think

@larsoner larsoner closed this as completed Apr 5, 2022
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

Successfully merging a pull request may close this issue.

4 participants