STL to ACIS SAT conversion
STL to ACIS SAT converter
=========================
Adam H. Aitkenhead
31st March 2010
Convert an STL file into an ACIS v4.0 SAT file (Standard ACIS Text), which can be more readily imported into various CAD packages (including Solidworks) as a solid model.
USAGE:
======
>> CONVERT_stl_to_sat(STLfilename)
or
>> CONVERT_stl_to_sat(STLfilename,STLformat)
converts the stl file <STLfilename> into an ACIS SAT file. The optional string <STLformat> defines the format of the STL file as one the following:
'auto' - (The default option) Automatic detection of the file format
'ascii' - ASCII format
'binary' - Binary format
EXAMPLE:
========
>> CONVERT_stl_to_sat('sample.stl')
converts the STL file 'sample.stl' into an ASIC SAT file called 'sample.sat'.
STL REQUIREMENTS:
=================
The STL data must meet the following criteria:
1. All facets are triangular.
2. No duplicate or overlapping facets exist.
3. The mesh is properly closed.
4. The facet normals are properly defined.
5. For each facet edge, there must exist an odd number of identical edges on adjacent facets.
Although uncommon, some STL meshes may not meet requirement 5 and cannot be converted to SAT using this code.
OTHER NOTES
===========
For a description of the ACIS format, refer to: http://local.wasp.uwa.edu.au/~pbourke/dataformats/sat/sat.pdf
Depending on the hardware, conversion is performed reasonably quickly for STL meshes of up to a few thousand facets. For larger meshes the conversion time increases roughly with the square of the number of facets.
Cite As
Adam A (2024). STL to ACIS SAT conversion (https://www.mathworks.com/matlabcentral/fileexchange/27174-stl-to-acis-sat-conversion), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform Compatibility
Windows macOS LinuxCategories
- Physical Modeling > Simscape Multibody > Model Import >
- MATLAB > Data Import and Analysis > Data Import and Export > Standard File Formats > STL (STereoLithography) >
- FPGA, ASIC, and SoC Development >
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
STL_to_SAT_conversion/
Version | Published | Release Notes | |
---|---|---|---|
1.9.0.0 | If the code fails due to a problematic facet, a plot is now displayed to show the location of that facet. |
||
1.8.0.0 | Added extra checks to test if the input mesh meets requirement 5. Also, small speed improvement for import of binary STL files. |
||
1.7.0.0 | Minor bug fix. |
||
1.6.0.0 | Another 20-25% speed improvement. |
||
1.5.0.0 | Optimised the WRITE_sat.m code, giving a speed increase of 30-40% for larger meshes. |
||
1.4.0.0 | Added automatic removal of zero-area facets. |
||
1.3.0.0 | Added H1 headers. |
||
1.2.0.0 | 7th April 2010: Optimisation of the WRITE_sat.m code. Conversion now runs 10-15% quicker for large meshes. |
||
1.0.0.0 |