v_sim.Line

Fields

None

Methods

class

newFromTriangles (data, nTriangles, isoValue)

draw (rgb)

free ()

getValue ()

project (plane, nSeg)

ref ()

unref ()

Details

class v_sim.Line

Structure representing a curved line in 3D, opaque structure.

classmethod newFromTriangles(data, nTriangles, isoValue)
Parameters:
  • data (float) – the lines to be computed ;

  • nTriangles (int) – the surface to compute isoline from ;

  • isoValue (float) – the value of the computed isoline.

Returns:

the newly allocated v_sim.Line or None.

Return type:

v_sim.Line

Create on the fly an isoline from a given set of triangles. If the lines are created, isoline will be allocated and should be freed with v_sim.Line.free() after use.

New in version 3.6.

draw(rgb)
Parameters:

rgb (float) – a colour.

Call the OpenGL routine that will draw this line.

New in version 3.4.

free()

Free the line object.

New in version 3.4.

getValue()
Returns:

the value associated to the line.

Return type:

float

Lines are usually created as iso-values line in a mesh.

New in version 3.6.

project(plane, nSeg)
Parameters:
Returns:

a newly allocated array of line segments. The size of this array is 4 * nSeg, holding the two plane coordiantes of the two vertices of a line.

Return type:

float

Calculate the projection of each self vertex on plane.

New in version 3.6.

ref()
Returns:

itself.

Return type:

v_sim.Line

Increase the ref counter.

New in version 3.7.

unref()

Decrease the ref counter, free all memory if counter reachs zero.

New in version 3.7.