yade.qt module

Common initialization core for yade.

This file is executed when anything is imported from yade for the first time. It loads yade plugins and injects c++ class constructors to the __builtins__ (that might change in the future, though) namespace, making them available everywhere.

class yade.qt._GLViewer.GLViewer
__init__()

Raises an exception This class cannot be instantiated from Python

axes

Show arrows for axes.

center((GLViewer)arg1[, (bool)median=True]) → None :

Center view. View is centered either so that all bodies fit inside (median = False), or so that 75% of bodies fit inside (median = True).

close((GLViewer)arg1) → None
eyePosition

Camera position.

fitAABB((GLViewer)arg1, (Vector3)mn, (Vector3)mx) → None :

Adjust scene bounds so that Axis-aligned bounding box given by its lower and upper corners mn, mx fits in.

fitSphere((GLViewer)arg1, (Vector3)center, (float)radius) → None :

Adjust scene bounds so that sphere given by center and radius fits in.

fps

Show frames per second indicator.

grid

Display square grid in zero planes, as 3-tuple of bools for yz, xz, xy planes.

loadState((GLViewer)arg1[, (str)stateFilename='.qglviewer.xml']) → None :

Load display parameters from file saved previously into.

lookAt

Point at which camera is directed.

ortho

Whether orthographic projection is used; if false, use perspective projection.

saveSnapshot((GLViewer)arg1, (str)filename) → None :

Save the current view to image file

saveState((GLViewer)arg1[, (str)stateFilename='.qglviewer.xml']) → None :

Save display parameters into a file. Saves state for both GLViewer and associated OpenGLRenderer.

scale

Scale of the view (?)

sceneRadius

Visible scene radius.

screenSize

Size of the viewer’s window, in scree pixels

selection
showEntireScene((GLViewer)arg1) → None
timeDisp

Time displayed on in the vindow; is a string composed of characters r, v, i standing respectively for real time, virtual time, iteration number.

upVector

Vector that will be shown oriented up on the screen.

viewDir

Camera orientation (as vector).

yade.qt._GLViewer.Renderer() → OpenGLRenderer

Return the active OpenGLRenderer object.

yade.qt._GLViewer.View() → GLViewer

Create a new 3d view.

yade.qt._GLViewer.center() → None

Center all views.

yade.qt._GLViewer.views() → list

Return list of all open qt.GLViewer objects