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

Can't import OpenSCADUtils #8

Open
Antony74 opened this issue Jul 2, 2024 · 0 comments
Open

Can't import OpenSCADUtils #8

Antony74 opened this issue Jul 2, 2024 · 0 comments

Comments

@Antony74
Copy link

Antony74 commented Jul 2, 2024

C:\>docker run -it amrit3701/freecad-cli python3
Python 3.6.9 (default, Jul 17 2020, 12:50:27)
[GCC 8.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import FreeCAD
>>> import Mesh
>>> import OpenSCADUtils
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/Mod/OpenSCAD/OpenSCADUtils.py", line 31, in <module>
    from exportCSG import mesh2polyhedron
  File "/usr/local/Mod/OpenSCAD/exportCSG.py", line 35, in <module>
    try: import FreeCADGui
ModuleNotFoundError: No module named 'FreeCADGui'

Obviously it has a dependency on the front end, and we're trying to run headless, so I doubt this is going to be an easy problem to solve.

Any general advice on how to get the union of two meshes in an automated fashion, please? I've tried pymesh. I've tried converting to a Part.Shape with makeShapeFromMesh and calling fuse. Neither approach yeilds a mesh which is valid according to or repairs correctly in FreeCAD. The OpenSCAD workbench in FreeCAD does it nicely, but is now putting up a fight when I try to automate it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant