Setting InteractorStyleTerrain does nothing in Jupyter
- Dominant language
- Python
- Stars
- 1.4k
- Forks
- 316
- Avg merge
- 7h 44m
- Merged PRs (30d)
- 5
Description
I want to keep Z axis up. In [1] I've found
`from tvtk.api import tvtk`
`fig = mlab.gcf()`
`fig.scene.interactor.interactor_style = tvtk.InteractorStyleTerrain()`
does that.
This code works as expected in a cell in Jupyter (opens new mayavi window):
`%gui qt`
`from mayavi import mlab`
`from tvtk.api import tvtk`
`fig = mlab.gcf()`
`fig.scene.interactor.interactor_style = tvtk.InteractorStyleTerrain()`
`mlab.test_barchart()`
This code doesn't:
`from mayavi import mlab`
`mlab.init_notebook()`
`from tvtk.api import tvtk`
`fig = mlab.gcf()`
`fig.scene.interactor.interactor_style = tvtk.InteractorStyleTerrain()`
`mlab.test_barchart()`
It shows the barchart in the notebook, but still allows me to turn it upside down.
[1] https://stackoverflow.com/questions/14225512/constrain-mayavi-mouse-drag-to-rotating-earth-around-its-axis
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.