I have written a python script that uses Preform Server local API to load .form, .obj, .stl and .stp files, pack them and display statistics. If models need repair it can optionally call a Python mesh repair library. Finally it can calculate the cost of materials like Preform does. I’ll be creating a public github repro for it soon. Anyone have any feature requests?
usage: sls_packing_analyzer.py [-h] [--server-path SERVER_PATH] [--port PORT] [--machine MACHINE] [--material MATERIAL] [--spacing SPACING] [--list-materials]
[--auto-repair] [--cost-per-kg COST_PER_KG]
[files ...]
Analyze SLS packing efficiency for Formlabs Fuse printers
positional arguments:
files One or more 3D model files (.form, .stl, .obj, .step, .stp)
optional arguments:
-h, --help show this help message and exit
--server-path SERVER_PATH
Path to PreFormServer installation (auto-detected if not specified)
--port PORT Port for PreFormServer (default: 44388)
--machine MACHINE Machine type (e.g., FUSE-1-0, FUSE-1+-30W-0). Use --list-materials to see all options.
--material MATERIAL Material code (e.g., FLNYL2PA for Nylon 12). Use --list-materials to see all options.
--spacing SPACING Model spacing in mm (default: 5.0)
--list-materials List available machine types and materials, then exit
--auto-repair Attempt to repair models automatically if import fails (experimental)
--cost-per-kg COST_PER_KG
Cost of powder per kg in USD (default: 120.0)
Examples:
sls_packing_analyzer.py part1.form part2.form part3.form
sls_packing_analyzer.py part1.stl part2.stl part3.obj
sls_packing_analyzer.py model.step --machine FUSE-1+ --material FLNYL2PA
sls_packing_analyzer.py *.stl --server-path /path/to/PreFormServer
sls_packing_analyzer.py part1.stl part2.obj --spacing 3.0
sls_packing_analyzer.py broken.stl --auto-repair
Supported file formats:
.form - Formlabs PreForm scene files
.stl - STereoLithography files
.obj - Wavefront OBJ files
.step - STEP 3D CAD files
.stp - STEP files (alternative extension)
Note: For best results with combinations, use STL/OBJ/STEP files.
Multiple .form files in combinations will only use the first file as base.