Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The corresponding IndexFaceSet is not enclosed. According to documentation:

is_enclosed()

Return a boolean telling whether or not it is necessary to render the back sides of the polygons (assuming, of course, that they have the correct orientation).

This is calculated in by verifying the opposite edges of the rendered domain either line up or are pinched together.

I do not know a reason for why it's not enclosed, but one can extract edges (as tuples of points) from the faces like:

edge_set = set.union( *[ {(f[0],f[1]),(f[0],f[2]),(f[1],f[2])} for f in map(sorted,pl.faces()) ] )

The corresponding IndexFaceSet is not enclosed. According to documentation:

is_enclosed()

Return a boolean telling whether or not it is necessary to render the back sides of the polygons (assuming, of course, that they have the correct orientation).

This is calculated in by verifying the opposite edges of the rendered domain either line up or are pinched together.

I do not know a reason for why it's not enclosed, but one can extract edges (as tuples of points) from the faces like:

edge_set = set.union( *[ {(f[0],f[1]),(f[0],f[2]),(f[1],f[2])} for f in map(sorted,pl.faces()) ] ) )

The corresponding IndexFaceSet is not enclosed. According to documentation:

is_enclosed()

Return a boolean telling whether or not it is necessary to render the back sides of the polygons (assuming, of course, that they have the correct orientation).

This is calculated in by verifying the opposite edges of the rendered domain either line up or are pinched together.

I do not know a reason for why it's not enclosed, but one can extract edges (as tuples of points) from the faces like:

edge_set = set.union( *[ {(f[0],f[1]),(f[0],f[2]),(f[1],f[2])} for f in map(sorted,pl.faces()) ] )

Here points in each face are first sorted to ensure that they are consistently appear as first/second elements of edges, and then 3 edges (i.e. sides of the triangle) are extracted from it. We form a set to exclude duplicated edges, later it can be converted to a list if needed. In the given example, there are 1,074 distinct edges.

The corresponding IndexFaceSet is not enclosed. According to documentation:

is_enclosed()

Return a boolean telling whether or not it is necessary to render the back sides of the polygons (assuming, of course, that they have the correct orientation).

This is calculated in by verifying the opposite edges of the rendered domain either line up or are pinched together.

I do not know a reason for why it's not enclosed, but one can extract edges (as tuples of points) from the faces like:

edge_set = set.union( *[ {(f[0],f[1]),(f[0],f[2]),(f[1],f[2])} for f in map(sorted,pl.faces()) ] )

Here the points in each face are first sorted to ensure that they are will consistently appear as first/second elements of edges, and then 3 edges (i.e. sides of the triangle) are extracted from it. We form a set to exclude duplicated edges, later it can be converted to a list if needed. In the given example, there are 1,074 distinct edges.