pele.gui.show3d_with_slider#

class pele.gui.show3d_with_slider.Show3DWithSlider[source]

Source

class Show3DWithSlider(QWidget):

The main OpenGL viewer for pele

This viewer can display a single structure, two structures overlaid, or a pathway of structures (with a slider)

Show3DWithSlider.setSystem()[source]

Source

def setSystem(self, system):

set the system which has information about how to draw the structures.

it should have a function:

system.draw(coords)

Show3DWithSlider.setCoords()[source]

Source

def setCoords(self, coords, index=1):

display a structure (not a path) in the ogl viewer

Parameters:
coords1d array

the structure to display

index1 or 2

the viewer can display two structures overlayed. This specifies whether this structure should be in slot 1 or slot 2

Show3DWithSlider.setCoordsPath()[source]

Source

def setCoordsPath(self, coordspath, frame=None, labels=None):

show a path in the viewer

Parameters:
coordspath2d numpy array

coordspath[i,j] is the coordinates of the j’th degree of freedom of the i’th structure

frameint

frame number to show initially

labelslist of strings

labels for the structures that will be shown above the ogl viewer