Question
I'm just discovering X3DOM and playing with it. I have draw a chair with sketchup and converted to x3d with meshlab. I'm using the "html5" syntax to write my page. Depending on "something" I have diferent rendering and I don't know what.
Rendering I consider ok: http://aws.ysagon.com/x3d/x3dom/ok.html
Rendering I consider not ok: http://aws.ysagon.com/x3d/x3dom/bad.html
What bother me is that the one I consider ok is the one with html error (the tag <Coordinate>
is self closed and should not). In the bad example, the tag is not self closed.
Can someone please explain me why it seems to have two rendering mode?
Thanks!
Solution 2
Ok I figured out what was the problem. When there is a syntax error in my html file, the <Normal vector" ...">
isn't used and in my case without this vector the rendering appears better. I now have to figure why!
edit:
The normal vector was "wrong" (at least for x3dom). Generating a correct normal vector along with the object did the trick. So it seems it's better to have no normal than a "bad" normal.
OTHER TIPS
HTML5 doesn't work too well with X3DOM, in fact, X3DOM is the result of JavaScript and HTML talking the Shockwave Flash syntax. I have no clue how you got it to work with HTML5, but flash is recommended.
Okay, I have some solutions that might or might not work.
1.Get into the X3D file with a text application. (Any, TextWrangler is recommended)
2.Use another 3D modeling program. (Blender works fine, so I recommend it)
3.Does the object have a big file size?... (BIG as in over ~50 MB) because X3DOM is trying to do whatever it can to render the object file.