STEP vs STL is there a difference in print quality?

I believe the mainstream use of stl files is intentional for several reasons. Here is my guess on why stl is more widely used.

First, stl files have been used long before most of us even thought of the idea of 3D printing. Remember stereolithography prototypes? I’m talking about those really brittle yellow things that engineers had laying around their office from the 80s-90s. They used CAD programs and outputted as stl before mesh programs became widely available.

Second, open source programs like blender have been far more successful and easier for a non-engineer to get their hands on and learn compared to the available CAD software that was readily available when 3D printing became more of a hobby opportunity. This appealed to the 3D printing industry because it increased the target audience.

Third, g-code. G-code has also been around forever. It’s used in programming CNC paths to make a part using CNC machines. CNC and 3D printing are axis limited. That is, they don’t technically just float around in space carving like an artist might that is making a sculpture. So, triangles give direct paths for G-code to output as coordinates.

Lastly, and this is coming from someone who designs specifically for injection molding often, an stl file compared to a step / iges / xt / xb is like a pdf compared to a word doc or even better a jpeg compared to a native photoshop image. Yes, you have all that you need on the outside, but you can’t go back and edit the step by step process that was used to create the file if you don’t have the native format. So, mesh programs effectively are like taking an existing jpeg and then bringing it into photoshop to manipulate from a frozen period in time. You’re limited by the saved data within the jpeg. No injection molder will take an stl file because it’s inherently a screenshot of file to them. It’s a like a snapshot of a picture to them.

Again, this is all my take, but maybe it can help to understand the difference from another angle.

1 Like

A mesh/stl is not a dumb file, just as a black and white photograph is not dumb compared to a colored one. It captures the essence. It is a 3-dimensional raster of an object with exact vertices/corner coordinates of triangles that defines its surface and if you want interior space and even contains ‘normal’ vectors of these triangles telling you if one is reversed/out of order for repair. The ‘normals’ can be used to manipulate the triangles, distorting the mesh, like ‘grab handles’ by moving the triangles in space. The resolution is only limited by the number of triangles like a bitmap picture is limited by the DPI. And of course the floating point resotution of the vertices’ values. Am I wrong?

Yes, you are correct. Maybe dumb was not the best term. It captures the essence, absolutely. Unlike a black and white image though, it can’t be converted back to ‘color’. Converting a stl back to step will not reduce or eliminate triangles as opposed to converting a b/w photo back to color which will actually give it color. Thanks for the correction though. Much appreciated!

Let’s stay with analogies. There is no converting a b&w images back to color, you can colorize it, but you don’t know what the ‘original’ colors were. So it’s more a guessed transformation than a restoration, unless you have the original image. Similar with stl to step. I suppose. I don’t know the of the algorithns used and I am not an expert code writer. I just used programs like Alias Maya and VRML files in the past. They all use meshes with polygones including triangles. You can add surface textures, colors, material simulation etc as you desire, Same as with stl meshes used for 3D printing. You can use different materials/filaments FDM, SLS etc. to create a real object from the mesh. All of it is not exactly duplicating a real life object, but ‘inventing’ or ‘manifesting’ the vision of the designer with an artistic or thechnical/functional purpose in mind. Some similarities to photography, but that’s where it ends. I thinkthough as in photography, we are limited by the capabilities and the ‘resolution’ of the technology we are employing. Even the highest resolution source file is limited by the capabilities of the slicer and then the 3D printer. The printer’s resolution is limited by nozzles size and precision of xyz movement, even laser sintering or CNC machining is limited. Perhaps injection molding is better since it is only limited by the precision of the mold which can be very precise.
But I think I digressed. Back to the stl/step issue. What I wanted to point out is that when the slicer goes to work it creates cross-sections of the object, intersections of the slicing plane with the mesh, i.e. a 2-dimensional representation. Then the printer finds a way to lay down material to best approximate the 2D representation. Point to point straight line connections, approximated curves (in walls) you name it. They are all ‘steps’, So stl or step the printer’s capabilities is the final deciding factor. To use another analogy, lol, the best audio source becomes mediocre when paired with lousy loud speakers. I have not even mentioned the fact that the printing material can deform and shrink after a print, And this can not completely controlled or compensated for. So there goes precision agaiin,
How is that for a New Years rant. I better stop. What did I miss or get wrong? Please enlighten me and forgive my lack of professional insight. And my misspellings.
Happy New Year 2024. Hoping/wishing for peace in the world and resolution of political turmoil in some ‘special’ parts of the world.

From the link in the second post of this thread:

The STEP file saves models without accuracy loss. The original STEP file is the vector model, when importing the STEP file, Bambu Studio converts models into triangular mesh automatically according to a tolerance that is small than the half of default arc fitting tolerance. That is, it is converted into a high-precision STL model in Bambu Studio. Therefore, more outline details of the model can be reserved, so that more G2/G3 arc move G-code can be generated when slicing.

This is the relevant section for using STEP files with arc fitting, there’s absolutely a difference in print quality and it’s pretty important for getting this design to work as well as it does.

So if you save the model in a ‘high precision’ stl file like the one created by Bambu studio in the CAD program in the first place, and import it, shouldn’t the outcome be the same? Or is that not possible? Doubt it.

The limiting factor will always be how well the slicer ‘implements’ the model shapes and features in G-code and how well the printer is able to ‘materialize’ these shapes and features. That will also depend on you, on how well you set up all the print parameters and what ‘material’ i.e. filament you choose. I consider these as important as whether you use a step or stl file appropriately high precision.

The AI says:

Yes, STEP files generally offer a higher resolution than STL files. Here are some differences between the two:

  • STL files (STL stands for “Stereolithography”) are specifically designed for creating 3D prints. They consist of triangles that shape the model and give surface details. STL files are easy to generate and can be quickly printed on a 3D printer.

  • STEP files (Standard for Exchange of Product Model Data) are used to store and transfer complex 3D models with many different features. It is a more detailed file format than STL, giving users more control over the features and properties of the 3D model.

In practice, this means that if you want to share CAD data with an external manufacturer so they can manufacture the part you modeled in CAD, or share CAD data with a customer so they can explore and edit your CAD file, you would use STEP files. On the other hand, if you want to share CAD data so it can be 3D printed, you would send STL files, as these are perfect for 3D printers and the file size is not very large.

However, it’s important to note that the resolution of STL files can also vary. Low-resolution STL files show noticeable flat surfaces in curved parts, while high-resolution STL files show a rather blurry gradient. But generally, STEP provides more detail than STL.

:wink:

This is EXACTLY the frustrating disinformation I’ve been trying to combat throughout this thread. This statement is categorically false!!! It shows a complete misunderstanding of what a step file is and is not. What’s worse, is that statements like this only serve to perpetuate this misunderstanding.

“There is no such thing as a high resolution STEP file.”


Riddle me this.

  1. How thick is a 1 meter line?
  2. What is the width in meters of the base of a 30° arc?

Let’s go over this one more time with pictures.

Here is the actual code in text from a 10mm sphere represented in CAD and exported from the same CAD drawing. One in STEP and one in STL.

It took 5,686 lines of code to represent individual triangles - 826 triangles to be exact - to approximate the shape of a sphere the example 10mm sphere using an STL file.
image

But it took only 100 lines of code to generate a STEP file which the slicer was able to render into 16,704 triangles. It was at that point that all arc and mathematical constructs are destroyed once the model is imported.
image

Why is this? Because in the STEP file it tells the computer to draw a sphere – in this case 10mm in diameter – and the computer does the math.

In an STL file, the creation process has to approximate the sphere into many triangles in order to achieve a far less precise result(see below). It gets even worse as the part is scaled up, just like the blockyness one sees when one upscales a bitmapped image.

Here is visual proof of the same file imported into the slicer. Note that even though the STL file had 5,686 lines versus the STEP having just 100 lines of text, the slicer was able to smooth out the model based on the resolution the developers chose.

_____________________________________________________

If one can remember two things.

1) A STEP file can be scaled infinitely without loss of shape or resolution, an STL file cannot.

2) A STEP file can be converted into a mesh, an STL cannot be converted back to a STEP file without severe loss of geometric data, some programs that claim they can do this can actually only approximate this.

2 Likes

STl files not even contain the unit which should be used. Could be metric ore inch. The slicer has to assume it or the user has to tell it to / configure the slicer.
While most expect metric there could be surprises.

What about ‘interpolation’, adding triangles when you scale up an stl, same as up-scaling a bitmap? You can add triangles by subdividing a triangle and using the neigboring normal vectors for alignment. You are not stuck with the initial resolution. It might get complicated and distort the shape if one (the algorithm) is not careful or efficient. The only downside is the file size might get big, perhaps enormous. But what does size concern these days with tera storgae. Perhaps processing takes longer but todays processors with multi -cores and speed can handle it.
I am just being a bit facetious here, but are we talking about CAD design and CAD data exchange here or 3D printing for the consumer? From the elitist point of view, of course STEP files are the bee’s knees. But the slicer takes that bee’s knees and makes triangles out of it and then slicing planes for printing based on these triangles. And then perhaps the clumsy printer screws it up because the owner didn’t pick the parameters well, and ‘nozzles’ through it.
So let’s be realistic. STL files work fine for most of us. If you want good resolution and your CAD program supports stl scaling, just export a very high resolution stl.
After reading all these comments, I think the whole step/stl issue is academic, philosophical, theoretical to me now. I don’t design medical devices or complex machinery parts or for the goverment. So I stick with whatever stl file I can get on yeggi, if it’s step, also good. I am more struggling with and am concerned about getting to learn the ins and outs of the slicer and creating prints that look like what I had in mind. If it doesn’t fit or look great first I try again, and again. waste of filament? Maybe. Fun? Most of the time. But who cares. It’s a hobby. I leave the worries to people who make their living of it.
So I wanted to thank all of you who paticipated here and gave detailed information and academic viewpoints. As a former(?) academic/academician myself I appreciate it, the intellectual back and forth. Am used to it.
I wish everybody a productive and interesting (not in the Chinese proverbial meaning) new year.
Happy 3D-ing.

From the onset, I’ve conceded that in most use cases, people printing 3D models of the latest Grogu or Dwayne Johnson rocktopus would never see the difference.

But that wasn’t the orginal post topic was it? Wasn’t it about difference in quality? Wasn’t the whole point of the post to determine if there is a difference?

The difference may appear to be academic until one tries to make a part that has to fit. 3D printing struggles already in this area and STL files only make the matters worse.

So is this academic? For those who are printing craft items, yes, they can get by with just about anything. For those printing parts? Emphatically NO! It is far from academic when two parts you just tried to print won’t mate when you connect them. Or if you are making a part that has to intermate with a part that you didn’t design. Then accuracy takes on a whole other meaning doesn’t it.

As far as interpolation goes? Ok. Let’s interpolate something.

1) Scaled bitmap by zooming in on an image.

______________________________________________________

2) Scaled in browser where the graphics card decides where the pixels go.

______________________________________________________

Which one is preferable? This is the distinction between interpolated and mathematical reproduction. If one does not feel that such a thing is important, then the next logical question is why did one bother spending $600-$1,200 on a PS1 or X1 printer when an Ender 3 can be had for $169?
image

I was talking about 'mathematical interpolation types, nearest-neighbor, bilinear and bicubic, not plain zooming. Similar methods should be applicable to meshes. Besides any computer calculation is an approximation since you are dealing with the limitation of floating point arithmetic. The grahics card is limited by it and so are the algorithms used by CAD programs. Even when you use CAM or CNC you are limited by the precision of those methods. They are just ‘very precise’ or precise enough for the application/production. That’s what production standards and requirements are for. You have to keep in mind what your method can do, chose the one most suitable and necessary. If you fall short on precision, find a betterone. But for me the resolution of current 3D printers is an issue sometimes. Not so much precision. I tried to print a 0.1mm washer/spacer (silly me) and it wouldn’t let me , of course, with a .4mm nozzle. We are just still in the coarse world/universe of FDM, Fused deposition MODELING, creating draft objects, but not facsimiles of originals. Not electron beam melting. Or atomic-molecular arranging and composing in a Star-Trek-like replicator. Prototyping is what we ‘commoners’ do at best, and that not very well.

It is best to print a low-resolution mesh with a large nozzle. The smaller the nozzle, the more you will recognise the mesh structure on the object created. Unfortunately, you will also need much more time to complete the object if the nozzle is smaller. If the slicer is good, it will take the nozzle size into account to use a suitable mesh resolution when importing from STEP. For a 0.2 nozzle, the slicer would have to generate many more polygons to create an object of suitable quality from the data of a STEP file with the printer.

So select the appropriate nozzle size for your object, including the time required to create it. And you select the print speed, which is often decisive for the quality. You may also decide in favour of an even larger nozzle (0.6 nozzle, for example) because of the time required to complete the object. Then you can further reduce your mesh data (polygons) to make the file smaller if necessary.

If you are working with STL, you have defined the resolution. However, if you are the author of the STL, you can create a higher resolution STL with your software if you need to.

If the mesh data of an STL matches the resolution of the printer and the nozzle size, you will not notice any difference in accuracy.

If you are creating objects using polygons, you should know what you are doing.

Theres no advantage to using STL over STEP but there’s certainly an advantages to using STEP. At the end of the day if you just love triangles and STL files you’re more than welcome to use whatever file format you want but don’t expect designers to always provide STL files when STEP files are just better in every way.

edit: for what it’s worth back in 2015 I created a website that generated STL files for thousands of models so I’m pretty familiar with the file format since I basically coded my own file converter :slight_smile: .

1 Like

So Brent, after following all this discussion I am still confused. Nobody just ‘loves triangles’ and stl files per se, it’s just a common format and it is easier to get designs in stl format. But as I understand it, the slicer programs convert step files into triangle-based files on import, right? Or did I misunderstand this? But if so what is the difference between a CAD-exported stl file and a ‘slicer-comverted from step’. ‘stl-like’ format ? Given that the resolution can be adjusted when exporting in stl format, are CAD programs less efficient/accurate in exporting stl format than slicer programs in converting from step? What is it that I am missing here?

You’re missing this example. STL on the left, STEP on the right.

Let’s simplify it, if I’m designing a circle why would I use triangles to approximate it when I can use a vectorized circle that matches exactly? It’s about best practices when designing new parts and I also prefer to let the slicer tesselate my model according to its own parameters and algorithm because that is how Bambu Studio implemented and tested that feature. If you have any advantages of STL please share.

But the pictures dont tell me what ‘resolution’ each example is based on. Could be a low resolutioh, crappy stl file and a very efficient slicer conversion on the right. Which could be achieved by creating and loading a high resolution stl file. My question is still unanswered. Does the slicer, any slicer, just convert the step file data to an stl-like format, of higher/better resolution than any/most stl files out there? And then is the G-code generated from this format ‘superior’ to any G-code generated from stl files? As in no matter what stl file I use, it will always have an inferior print outcame than any step-file-based print? Then, what makes the conversion of step file to slicer format to G-code so much superior to the same process from stl file format? I have not looked at the ‘internal’ format used by the slicer to generate G-code from so I am just asking. Can someone explain to me what the slicer program does internally? Are there differences between slicers?
Anyway this is not a theoretical question but a very practical. If stl format based objects will always have an inferior print outcome then of course one should only use step-based object files for printing or convert to step, however inferior it is to original step format in the first place. And slicers should use these algorithns when importing stl format. Do they already? Shouldn’t they strive to get close to or ‘simulate’ step quality if it is so much better? Are these ‘lousy’ results you show from stl file data based on an inefficient implementation of these algorithms? I am aware that there is not much better you can do with a really bad, low resolution stl file. But in general there should be a way to ‘interpolate’ stl meshes. adding triangles and improve the resolution before the actual slicing process internally.

So step → slicer ‘tessellated’ mesh and stl → slicer ‘tessellated’ mesh.
Which comes out better? Depends on the ‘tessellator’.(Triangulator, 'Meshalator’lol).
Same would be true if you had a lousy implementation of the G-code
generated to run CAM and CNC processes. But they have been perfected over decades. Why not for 3D printing? Or are they and it’s all the fault of lousy printers and the lousy stl files the CAD software is generating? The printers can do better with step input so it seems. So shouldn’t we drop stl altogether, abandon it and switch completely to step?