STL Format

Next
 From:  DannyT (DANTAS)
6411.1 
Hi All,

Is there anyway to write a header in an STL file without corrupting it and if so, recommended editor?

Cheers
~Danny~
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
6411.2 In reply to 6411.1 
Hi Danny, well there are 2 different variations of the STL file format: ascii and binary.

The ascii type is a text file and can be edited in any text editor. The binary type can't be edited in a general text editor, you instead need to use a "hex editor" to edit it directly.

The header stuff is minimal in either variation - for ascii it's just the first line that says:

solid some_label_here

For a binary file the first 80 bytes of the file are considered to be the header and any kind of text label can go in those 80 bytes, it shouldn't make any difference if you change them.

So for a binary file use a hex editor and don't touch anything past the first 80 bytes and that should be fine.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  DannyT (DANTAS)
6411.3 In reply to 6411.2 
Thanks Michael,

What type of STL file does MoI export ascii or binary?

-
~Danny~
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
6411.4 In reply to 6411.3 
Binary I presume!

Line 1 said: MoI Binary STL

Before last line of a simple sphere said that! ;)

vÀ³ÂC?ÑÏ¿ Îì`¿w9±= sð¾¨ÄaÀKù%sÚÀ6ÜzÀSZ
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
6411.5 In reply to 6411.3 
Hi Danny,

> What type of STL file does MoI export ascii or binary?

It can export either type, depending on the setting under Options > Import/Export > STL options > "File type". That can be set to either Binary or Ascii, the default is binary.

When you write out an STL, if there is just one object being exported and it has a name, MoI will write the object name into that header spot, if the object is not named it will write a generic "MoI Binary STL" for binary files, and a plain "solid OBJECT" label for ascii files.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  DannyT (DANTAS)
6411.6 In reply to 6411.5 
Thanks again Michael, you make it all clear as usual.

Cheers
~Danny~
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  DannyT (DANTAS)
6411.7 
Done a bit of research and it seems STL binary is the way to go as it produces a smaller file size.
Downloaded a free Hex editor http://mh-nexus.de/en/hxd/ and now I can write information just for that little bit of extra copyright security even though someone can bring the file into another polygon program and export it out again then all info will be overwritten, that's if they check the header that is.

-
~Danny~
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  chrisd (CHRIS_DORDONI)
6411.8 In reply to 6411.7 
Danny, are you distributing the files for viewing purposes only?

3D PDF has somewhat better security in that not many applications can actually read and use the data in a 3d PDF file. Its possible to disallow saving to STL when you create the 3D PDF so Adobe Reader can't export an STL. Obviously that does not help if someone has an app that can convert the data directly from the 3D PDF (Simlab for example).
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  DannyT (DANTAS)
6411.9 In reply to 6411.8 
Hi Chris,

> are you distributing the files for viewing purposes only?

It's for 3d printing purposes, I just wanted to put something in there in the case someone is sharing the file as their own.
Having Simlab composer myself, yes I would use 3d PDF if the file was for viewing purposes only.

Cheers
~Danny~
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All