2

I want to convert a VRML 3D object to a JSON object (automatically got some thousand object) in oder to load it into my HTML side.

I tried it with some converter I found but it still doesn't work.

I tried the J3D.engine but I only can use models exported from Unity.

Does somebody have some experience in converting and adding 3D models?

Bart
  • 19,692
  • 7
  • 68
  • 77
Phipps
  • 355
  • 1
  • 3
  • 10

1 Answers1

0

If you can convert your VRML to X3D XML, you can use this XSLT code to convert to JSON: http://www.web3d.org/x3d/stylesheets/X3dToJson.xslt Note that it will currently put your VRML ECMAscripts on one line. We're working on it, but it's not a priority. I believe the stylesheet needs run with an XSLT 2.0 stylesheet runner, and Saxon-CE doesn't work in all cases. Saxon-HE seems to work better. I believe there's a native Java XSLT runner that may work as well.

John Carlson
  • 321
  • 1
  • 13