Exporting low-polygon STL files for shading geometry
This guide covers how to export a low-polygon STL from SolidWorks or Onshape for use as shading geometry in SunSolve Yield. The goal is a mesh that captures the outer envelope of a part accurately enough to model shading impact, without unnecessary geometric detail. Meshes with more than 10,000 triangles can be simplified during import using the built-in simplification tool on the preview tab. For details on importing STL files into SunSolve Yield, see Custom objects.
Why low polygon count matters
Section titled “Why low polygon count matters”For shading geometry, you only need the gross shape of a component — the silhouette that blocks light. Fine surface detail (bolt heads, chamfers, fillets, cable glands) adds triangles without meaningfully changing the shading result. A motor housing rendered as a rough 10-sided polygon is indistinguishable from a smooth cylinder at the scale of a solar array.
Targeting a low polygon count also keeps your simulation scene light and fast to compute, and helps you stay within the scene size limits above.
Choosing your settings
Section titled “Choosing your settings”Three parameters control triangle count in SolidWorks STL export:
Angular deviation, Maximum angle between adjacent facet normals. Higher = fewer triangles on curved surfaces.
Chordal tolerance, Maximum distance between the mesh and the true surface. Higher = fewer triangles overall.
Minimum facet width, Smallest triangle edge allowed. Higher = prevents slivers but also removes fine detail.
Recommended settings by part size
Section titled “Recommended settings by part size”Rule of thumb: Set chordal tolerance to approximately 10% of the largest dimension of the part.
SolidWorks export workflow
Section titled “SolidWorks export workflow”Step 1 — Suppress unnecessary features
Section titled “Step 1 — Suppress unnecessary features”Before exporting, suppress any fine detail that won’t affect shading:
- Bolt holes and fasteners
- Chamfers and small fillets
- Connectors, cable glands, and labels
Right-click features in the Feature Tree and select Suppress.
Step 2 — Save as STL
Section titled “Step 2 — Save as STL”- Go to File > Save As
- In the Save as type dropdown, select STL (*.stl)
- Click Options before saving
Step 3 — Set export options
Section titled “Step 3 — Set export options”In the Options dialog:
- Set Resolution to Custom
- Set Deviation to your target chordal tolerance (e.g.
0.1for a 1 m part — note SolidWorks uses mm by default, so enter100mm) - Set Angle to
25–30degrees - Enable Save all components of an assembly in a single file if exporting an assembly
Click OK, then Save.
Step 4 — Verify the output
Section titled “Step 4 — Verify the output”Open the STL in a free viewer such as MeshLab or Microsoft 3D Viewer to confirm the shape looks correct and the triangle count is reasonable (typically 500–3,000 triangles for a motor assembly).
Check the file size — if it exceeds 5 MB, further decimation is needed (see below).
Onshape
Section titled “Onshape”Onshape
is a browser-based CAD platform with a free plan that supports STL export with configurable resolution settings. It is a good alternative if you do not have access to SolidWorks.
Step 1 — Simplify the model
Section titled “Step 1 — Simplify the model”As with SolidWorks, suppress or remove fine detail that won’t affect shading before exporting. Use Feature suppression or create a simplified configuration of your part.
Step 2 — Export as STL
Section titled “Step 2 — Export as STL”- Right-click the part or assembly in the parts list
- Select Export
- Set Format to STL
Step 3 — Set export options
Section titled “Step 3 — Set export options”In the export dialog:
- Set Resolution to Custom
- Set Chord tolerance to your target (e.g.
0.1for a 1 m part) - Set Max facet width to limit triangle density on flat surfaces
- Set Min facet width to prevent tiny slivers
- Adjust Angular tolerance to
25–30degrees
Click Export.
Step 4 — Verify the output
Section titled “Step 4 — Verify the output”Download the file and check it in a free viewer such as MeshLab to confirm the shape and triangle count are appropriate. Check the file size stays under 5 MB.
After export — further simplification
Section titled “After export — further simplification”If the resulting file still has more triangles than needed, you can simplify it during import. The import tool includes a built-in mesh simplification slider on the preview tab that lets you reduce the triangle count and see the result before importing. For best performance, aim for fewer than 10,000 triangles.