Introduction
X3D is the ISO standard for interactive 3D scenes, published by the Web3D Consortium as the successor to VRML. A scene is a graph of nodes: shapes with geometry and appearance, transforms, lights, viewpoints, and sensors and scripts that make the scene respond to the viewer. It is used in science, medicine, engineering and teaching, and can be shown in a web page.
The same scene can be written in several encodings: XML in .x3d files,
the VRML-like classic syntax in .x3dv files, and a binary form in
.x3db files.
Structure
An XML X3D file has the root element X3D with a profile and
a version, an optional head with metadata, and a
Scene holding the nodes. A Shape pairs a geometry node, such
as Box, Sphere or IndexedFaceSet, with an
Appearance and its Material. Transform nodes
move, rotate and scale their children. A node given a DEF name can be
reused elsewhere with USE.
<X3D profile="Interchange" version="3.3">
<Scene>
<Transform translation="0 1 0">
<Shape>
<Appearance><Material diffuseColor="0.8 0.2 0.2"/></Appearance>
<Box size="2 2 2"/>
</Shape>
</Transform>
</Scene>
</X3D>
Links
Software
- Castle Model Viewer (Windows, macOS, Linux)
- Blender (Windows, macOS, Linux), with its X3D add-on
- MeshLab (Windows, macOS, Linux)
Developers
Reference
- Web3D Consortium, with the X3D specifications