Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an 3D Export #1071

Open
Mannshoch opened this issue Jan 7, 2025 · 13 comments
Open

Add an 3D Export #1071

Mannshoch opened this issue Jan 7, 2025 · 13 comments
Labels
wontfix This will not be worked on

Comments

@Mannshoch
Copy link

In my case, I mostly have to work with 3D-DWG files.

I would like to have a possibility to extract 3D Data. The file format is not that important ( could be either, sat, step, iges, ifc )

Objects to extract: Surfaces, 3D-Body, meshes, etc.

Structure should be in any case an Assembly export

(e.g. STEP):

  • FileName
    • Layer-Name 1
      • Layer-Name 1- BodyName1
      • Layer-Name 1 - BodyName2
      • Layer-Name 1 - SurfaceName1
      • Layer-Name 1 - 3D-shapeName
    • Layer-Name 2
      • XREF1-Filename
        • Layer-Name D
          • Layer-Name D - BodyName1
        • Layer-Name A
          • Layer-Name A - BodyName2
        • Layer-Name A
          • Layer-Name A - SurfaceName1
@rurban
Copy link
Contributor

rurban commented Jan 7, 2025

That's too complicated and out of scope. We're exporting DWG, DXF or some private JSON. The json does contain the decrypted ACIS bodies.
Other packages can go from there, eg assimp or some modeler.

@rurban rurban added the wontfix This will not be worked on label Jan 7, 2025
@Mannshoch
Copy link
Author

ACIS bodies are SAT files. If I use AutoCAD and use SAT-filetype for exporting bodies from my dwg, only around the half of the bodies are exported. It seems that things like surface bodies are missing. I only get everything if I export to iges.

@rurban
Copy link
Contributor

rurban commented Jan 13, 2025

That's interesting.
Have you compared the AutoCAD SAT export with the SAT bodies from libredwg, e.g. in JSON? Because they can be in a special AcDsPrototype_1b section since 2013, as SAB binary ACIS data, version 2.
Which we also decode properly.

@Mannshoch
Copy link
Author

Sorry but I'm a CAD user not a developer. Your mention of JSON was interesting but I don't know what to do here.

I attached you an example. I imported the sat-file into a dwg.
Waschbecken.zip

@michal-josef-spacek
Copy link
Contributor

@Mannshoch Could you send DXF file of this file?

@michal-josef-spacek
Copy link
Contributor

michal-josef-spacek commented Jan 14, 2025

btw: There are 13 3DSOLID entities, which have issues in libredwg

@Mannshoch
Copy link
Author

Mannshoch commented Jan 15, 2025

You speak about #1028 (reply in thread) ?
what DXF version do you wish?

What kind of problems are there? As far that kind of data I usually have to work with. It's ok if they have error as long I could get them soemhow. I may could repair it with FreeCAD or other applications.

@michal-josef-spacek
Copy link
Contributor

@Mannshoch I am talking about Waschbecken.zip

The latest version of DXF as possible (ideally AC1032 for AC1032 dwg file)

About problem: Each version of DWG brings new features, your DWG file has multiple issues in 3DSOLID entity. The export to e.g. json isn't much helpful. For development is better to fix issues in older versions of DWG.

@rurban
Copy link
Contributor

rurban commented Jan 15, 2025

No, here are these undocumented classes, no ACIS solid's:

Warning: Unknown Class object 0 ACIMINTSYSVAR (0x8)
Warning: Unknown Class object 0 ACMSECTIONSTANDARDCUSTOM (0x8302is_zombie)
Warning: Unknown Class object 1024 ACMDETAILTANDARDCUSTOM (0x8079is_zombie)
Warning: Unknown Class object 10656 ACIMSYSVARMAN (0x3822)
Warning: Unknown Class object 12 AMDTNOTETEMPLATEDB (0xc006)
Warning: Unknown Class object 17 ACAMGHOLECHARTSTDDIN (0xf320)
Warning: Unknown Class object 20672 ACAMGTITLESTD (0xd2)
Warning: Unknown Class object 49212 ACAMCOMPDEF (0x40)
Warning: Unknown Class object 49212 ACAMCOMPDEFMGR (0x40)
Warning: Unknown Class object 49212 ACAMCONTEXTMODELER (0x40)
Warning: Unknown Class object 49212 ACAMGDIMSTD (0x40)
Warning: Unknown Class object 49212 ACAMGLAYSTD (0x40)
Warning: Unknown Class object 49212 ACAMGRCOMPDEF (0x40)
Warning: Unknown Class object 49212 ACAMPROJECT (0x40)
Warning: Unknown Class object 49212 ACGREFACADMASTER (0x41)
Warning: Unknown Class object 49212 ACGREFMASTER (0x40)
Warning: Unknown Class object 49212 ACIMSTRSYSVAR (0x40)
Warning: Unknown Class object 49212 ACMANOOTATIONVIEWSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMBOMSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMCENTERLINESTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMDATADICTIONARY (0x40)
Warning: Unknown Class object 49212 ACMDATUMSTANDARDDIN2008 (0x40)
Warning: Unknown Class object 49212 ACMDETAILSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMFCFSTANDARDDIN2008 (0x40)
Warning: Unknown Class object 49212 ACMIDSTANDARDDIN2012 (0x40)
Warning: Unknown Class object 49212 ACMNOTESTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMSECTIONSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMSURFSTANDARDDIN2002 (0x40)
Warning: Unknown Class object 49212 ACMTAPERSTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMTHREADLINESTANDARDDIN (0x40)
Warning: Unknown Class object 49212 ACMWELDSTANDARDDIN2014 (0x40)
Warning: Unknown Class object 49212 AMCONTEXTMGR (0x40)
Warning: Unknown Class object 49212 AMDTEDGESTANDARDDIN13715 (0x40)
Warning: Unknown Class object 49212 AMGOBJPROPCFG (0x41is_zombie)
Warning: Unknown Class object 49212 AMIMASTER (0x40)
Warning: Unknown Class object 49212 MAPIAMMOUDLE (0x40)
Warning: Unknown Class object 64 AMGSETTINGSOBJ (0x48)

@Mannshoch
Copy link
Author

Waschbecken2.zip

  • Waschbecken-orig.sat was the Original I used
  • Waschbecken-export.sat is the export I did after I imported it into dwg.
  • Waschbecken-mdt2025.dwg is the original dwg My AutoCAD 2025 Mechanical Desktop creates.
  • Waschbecken-2018.dwg is format 2018 from the save as dialog
  • Waschbecken-2018.dxf is the 2018 DXF format.

@michal-josef-spacek
Copy link
Contributor

@Mannshoch Thank you very much for testing data.

We have actually issues with:

  • 3DSOLID entity, probably resolvable, in entity data is probably link to database.
  • Decoding of "AcDs datastorage", not simple thing, SAT file is probably inside it. In DXF are some hints.
  • There are some XRECORD objects, I don't know what they are.

If you want to help us, you could create some small sat file with simple 3d object and insert it to autocad and send to us. (SAT, DWG and DXF files). Working on this big file isn't simple. This issue is not simple still.

@Mannshoch
Copy link
Author

May that is a binary SAT. From SAT files there are not only text files (.sat) also a binary filetype (.sab) does exist.
https://en.wikipedia.org/wiki/ACIS#File_format
googling for that gave me this here: http://www-isl.ece.arizona.edu/ACIS-docs/PDF/GET/03OV.PDF

@michal-josef-spacek
Copy link
Contributor

@Mannshoch I understand. There are situations like ACIS in REGION in ASCII form, converted to the next version of DWG and present in BINARY form.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

3 participants