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

Importing X3D objects into three.js #4239

Closed
xxdaggerxx opened this issue Dec 24, 2013 · 4 comments
Closed

Importing X3D objects into three.js #4239

xxdaggerxx opened this issue Dec 24, 2013 · 4 comments

Comments

@xxdaggerxx
Copy link

Hi everyone,
Is there a way to load X3D scenes into three.js?
Been searching all over the web and im surprised to find nothing on this issue.

Thanks very much for the help.

@cecilemuller
Copy link
Contributor

@xxdaggerxx Like mentioned in the reply to your(?) StackOverflow question, there is no X3D loader for three.js at the moment, but you could use X3DOM instead of three.js if you really have to use that file format.

Otherwise, you'd have to write your own loader or convert to another format as you suspected.


However, the tool Yvonne mentioned in the X3DOM issue is commandline, so you could make a webservice with it, then you could make ajax queries to the webservice to use it in client-side javascript.

Otherwise X3DOM being open source, so you could dig into its code and try to extract only the parts that deal with parsing the file, and write an OBJ file accordingly, but that would require good knowledge of the X3D and OBJ formats, and solid javascript knowledge. You could skip the first part by having a 1-pixel canvas with X3DOM to feed it the files to parse though.

@yjung
Copy link

yjung commented Dec 30, 2013

There is already an online service which comes along with aopt called Transcoder. Or check out this Framework: https://github.com/x3dom/pipeline

@cecilemuller
Copy link
Contributor

Sounds good :)

@mrdoob mrdoob closed this as completed Sep 3, 2015
@npolys
Copy link

npolys commented Feb 1, 2024

There are a few works since then.
However, one should be aware that X3D has Profiles so one can start w just geometry and still be compliant

X3D loaders need to be tested:
(in no order)

https://github.com/dividab/three-x3d-loader
https://www.npmjs.com/package/three-x3d-loader
https://codesandbox.io/s/x3d-loader-5ci2j
https://github.com/coderextreme/XThreeDLoader
https://github.com/svschub/x3djs

.x3dv encoding is like vrml-classic
VRML loader
https://threejs.org/examples/webgl_loader_vrml.html
works

X3Dv4 has passed International Ballot and is now and ISO/IEC Standard~
https://www.web3d.org/specifications/X3Dv4/ISO-IEC19775-1v4-IS

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

No branches or pull requests

5 participants