5

Does anyone know if there's a parser for autocad/cad formatted files in javascript? Or perhaps something server side which can translate cad files to collada so that three.js (and some of the other engines) could read them?

Thanks very much for any links and pointers.

Alex
  • 3,732
  • 5
  • 37
  • 59

2 Answers2

2

Python has an autocad lib http://pypi.python.org/pypi/pyautocad/ It provides json export. It works on Windows.

I think it can be a server-side solution if Python running on a Windows server is acceptable for you.

luc
  • 41,928
  • 25
  • 127
  • 172
  • Looks really interesting.. I'm going to keep the thread open for a bit in the hope that someone knows a browser based solution (or perhaps a php one which would be preferable) – Alex Nov 26 '12 at 11:41
1

You can take a look at OpenCascade and the community edition developed in C++. There seems to be an experimental COLLADA exporter done by the community edition.

If you prefer working with Python, you should see the pythonOCC project and particularly what they've done with Three.js: article and sources.

rochb
  • 2,249
  • 18
  • 26