18. marks — OpenGL marks for annotating 3D actors.

OpenGL marks for annotating 3D actors.

class marks.Mark(pos)

A 2D drawing inserted at a 3D position of the scene.

The minimum attributes and methods are:
pos : 3D point where the mark will be drawn draw() : function to draw the mark

Methods

Mark objects have the following methods:

class marks.AxesMark(pos, color=None)

Two viewport axes drawn at a 3D position.

Methods

AxesMark objects have the following methods:

drawGL(mode='wireframe', color=None)
class marks.TextMark(pos, text, color=None, font='sans', size=18)

A text drawn at a 3D position.

Methods

TextMark objects have the following methods:

drawGL(mode=None, color=None)
class marks.MarkList(pos, val, color=(0.0, 0.0, 0.0), font='sans', size=18, leader='')

A list of numbers drawn at 3D positions.

Methods

Create a number list.

pos is an (N,3) array of positions. val is an (N,) array of marks to be plot at those positions.

While intended to plot integer numbers, val can be any object that allows index operations for the required length N and allows its items to be formatted as a string.

Methods

MarkList objects have the following methods:

drawGL(mode=None, color=None)
drawpick()
This functions mimicks the drawing of a number list for picking.

Documentation

Previous topic

17. decors — 2D decorations for the OpenGL canvas.

Next topic

19. gluttext — 2D text decorations using GLUT fonts

This Page