I am new to the world of 3D graphics. I have a x3d file that i want to display in a web browser. I am trying to use the following code.
<Shape>
<Appearance>
<Material diffuseColor='0.6 0.0 0.6' specularColor='0.8 0.8 0.8' shininess='0.145'/>
</Appearance>
<inline url="full.x3d"> </inline>
</Shape>
This is written in a local html file and the "full.x3d" file is in the same directory as the html file. When I open the html file, the x3d box just shows loading... and nothing loads even after a long time.
The x3d file itself is fine. If i copy its contents manually to the html file, i get a good output.
I am not sure why x3dom is not picking up the data from the file. I am not using any local server, directly opening the html in the browser.
And this problem is not just limited to my file. When i downloaded and ran an example file from the x3d tutorial website, it also failed to load the attached x3d file.
Inline is not a field of a Shape.
Take that node outside the shape and it will work.
The inlined node should be a children of a grouping node (read specs).
There also an example here.