What is the about?

I work with 3D CAD creating 3D models. In the process I deal with exporting STL files and then uploading those files to Shapeways for printing or to submit to a slicer to create the G-Code for my Prusa i3 MK3 filament printer. That’s nothing unusual. What this is about is that STL file and how the file contains NOTHING to indicate units.

Following I created four cubes. They in turn measure an inch, a foot, a millimeter and a meter on a side. I then exported the STL file for each in ASCII so I could open in Notepad.

I removed the loops in each file as it does nothing but take up space for this discussion. I left the vertexes. There are 12 vertexes on a cube. This file locates those 12 vertexes and connects them with a line to form the cube we see on screen. I also deleted the carriage return for each line so the endfacet statement falls on the end .. simply to compact the text so I can show it.

Decimal Inches

Decimal Feet

Decimal Milimeters

Decimal Meters

UNITS?

What does this tell us?

IT DOES NOT MATTER WHAT UNITS YOU USE TO MODEL. The STL file only has numbers. In the above, every single vertex is listed as 1.0 or -1.0 .. doesn’t matter if inches, feet, millimeters or meters.

Why is this important?

Most slicers assume you are modeling in mm. When you upload a file to Shapeways you tell them what unit of measure you are modeling in. You upload a STL file and it doesn’t matter as the above shows if you modeled in in, feet, mm or m .. the STL file contains numbers only and if you tell Shapeways that it is in mm then that is what it will print the model at.

Sketchup was originally designed for Architects … and while it handles feet and inches and fractions just fine it balks at any radii below 0.018″. That is a problem for us that are modeling very small items such as in 1:97 or 1:48 scales.

Simple. I set my Units in Sketchup to inches and model in mm. If I want a cube that is 1 inch square then I model a cube 25.4 on a side .. that is it. When I upload to Shapeways or to a slicer I simply tell the website or the software that the model is in mm and everything prints EXACTLY to the size wanted.

END …. OF …. STORY

2 thoughts on “STL Files and Units and Printing”

  1. I’m not too sure what you are saying in last paragraph, are you saying you draw a 1” cube and tell shapeways to print a 1mm cube from the STL file or a 25.4mm cube from the STL file?

  2. If I am trying to create a cube exactly 1 inch on a side .. suppose. I set my Units of Measure to Inches but pretend that I am working in mm. I do this because I am effectively working 25.4 x the model actual sizes. When I export the file and either upload to Shapeways .. I tell them the model is in mm .. or .. load the STL file into my slicer .. it expects mm.

    So. Suppose I am working in HO .. and just suppose I want a cube that is EXACTLY one foot square in HO.

    Now .. in HO, a foot is .138 inches .. 12/87.1 = 0.1377~

    Convert .138 to mm … 0.138 x 25.4 = 3.5

    I open up Sketchup and under Windows–>Model Info I set units to Decimal Inches.

    I now draw a cube 3.5 x 3.5 x 3.5 .. yes .. I am drawing in inches but ignore that ..
    the reason is .. if I export the STL file ..you can export as an ACSII file and view in Notepad .. you will see .. 3.5, 3.5, 3.5 within the file. There are no inches, mm or any of that .. just the numbers. So you upload the file to Shapeways and tell them that it is in mm .. and it will print exactly.

    Why go through that? First .. you have complete control over the exact size of the model. Remember you are ‘pretending’ you are modeling in mm but you in reality are modeling in inches so you are modeling 25.4 x the actual size. That is important since Sketchup has problems with any radii below 0.018″

    If you need more help drop into my Whereby chat room .. link is under Social Media to the left and I can show you real time in Sketchup.

Leave a Reply

Your email address will not be published. Required fields are marked *


The maximum upload file size: 100 MB.
You can upload: image, audio, video, document, spreadsheet, interactive, other.
Links to YouTube, Facebook, Twitter and other services inserted in the comment text will be automatically embedded.