SupportStructure

class pyslm.support.SupportStructure(supportObject=None, supportVolume=None, supportSurface=None, intersectsPart=False)

Bases: ABC

The Support Structure is the base class representing all definitions of support structures used in PySLM. This includes attributes that link to the source part and the original support faces or features of an object and shared utility methods for the calculation of useful properties.

It stores properties that describe the type of support identified during its generation and stores relevant data connecting this such as the original support surface (supportSurface) and the support object or part (supportObject) and if the support self-intersects with the part (supportObject).

Attributes Summary

intersectsPart

Indicates if the projected support structure intersect with the originating part

supportObject

The originating object that the support structure is generated for.

supportSurface

The support surface identified on the originating part

volume

Returns the volume of the Support Geometry

Methods Summary

flattenSupportRegion(region)

The function takes a support surfaces and flattens this as a projected polygon.

geometry()

Returns the geometry representing the support structure

projectedSupportArea()

Convenience function returns the total projected surface area of the support region.

supportArea()

Convenience function returns the total surface area of the support region.

Attributes Documentation

intersectsPart

Indicates if the projected support structure intersect with the originating part

supportObject

The originating object that the support structure is generated for.

supportSurface

The support surface identified on the originating part

volume

Returns the volume of the Support Geometry

Methods Documentation

static flattenSupportRegion(region)

The function takes a support surfaces and flattens this as a projected polygon.

Parameters:

region (Trimesh) – The support surface as a trimesh.Trimesh mesh

Return type:

Polygon

Returns:

The 2D Polygon of the flattened surface

abstractmethod geometry()

Returns the geometry representing the support structure

Return type:

Trimesh

projectedSupportArea()

Convenience function returns the total projected surface area of the support region.

Note

The area returned is unit-less

Return type:

float

Returns:

The total projected (flattened) surface support area

supportArea()

Convenience function returns the total surface area of the support region.

Return type:

float

Returns:

The total surface area of the support