v_sim.SurfaceIterPoly

Fields

Name

Type

Access

Description

i

int

r/w

the index of the current polygon.

points

v_sim.SurfacePoints

r/w

the storage for polygons.

surf

v_sim.Surface

r/w

the parent v_sim.Surface.

valid

bool

r/w

a flag True, as long as the iterator is valid.

Methods

getVertices (vertices)

getZ (mat)

next ()

Details

class v_sim.SurfaceIterPoly

Structures used to iterate on polygons of surf.

New in version 3.8.

getVertices(vertices)
Parameters:

vertices ([v_sim.SurfacePoint]) – an array to store the vertex coordinates and normals.

Retrieve the position and normal of the point refered by self.

New in version 3.8.

getZ(mat)
Parameters:

mat (float) – a transformation matrix to go into viewport basis.

Returns:

True if polygon defined by self is drawn and z is computed

z:

a location to store double.

Return type:

(bool, z: float)

Retrieve the z value in the viewport basis of the drawn polygon defined by self. If the polygon is not drawn, z is not computed.

New in version 3.8.

next()

Iterate to the next drawn polygon.

New in version 3.8.