]> X3D XML encoding 4.0 draft - ISO/IEC 19776-1:202x - Annex A XML Document Type Definition (DTD)

Extensible 3D (X3D) encodings
Part 1: Extensible Markup Language (XML) encoding

Annex A

(informative)

X3D XML Document Type Definition (DTD)

--- X3D separator bar ---

cube A.1 Table of contents and introduction

A.1.1 Table of contents

This annex provides a detailed description of the grammar for each syntactic element in this part of ISO/IEC 19776. Table A.1 contains a table of contents that lists the topics in this clause:

Table A.1 — Table of contents

A.1 Table of contents and introduction
  A.1.1 Table of contents
  A.1.2 Introduction

A.2 Version 3.0 DOCTYPE documents
  A.2.1 x3d-3.0.dtd
  A.2.2 x3d-3.0-InputOutputFields.dtd
  A.2.3 x3d-3.0-Web3dExtensionsPublic.dtd
  A.2.4 x3d-3.0-Web3dExtensionsPrivate.dtd

A.3 Version 3.1 DOCTYPE documents
  A.3.1 x3d-3.1.dtd  
  A.3.2 x3d-3.1-InputOutputFields.dtd
  A.3.3 x3d-3.1-Web3dExtensionsPublic.dtd
  A.3.4 x3d-3.1-Web3dExtensionsPrivate.dtd

A.4 Version 3.2 DOCTYPE documents
  A.4.1 x3d-3.2.dtd
  A.4.2 x3d-3.2-InputOutputFields.dtd
  A.4.3 x3d-3.2-Web3dExtensionsPublic.dtd
  A.4.4 x3d-3.2-Web3dExtensionsPrivate.dtd

A.5 Version 3.3 DOCTYPE documents
  A.5.1 x3d-3.3.dtd
  A.5.2 x3d-3.3-InputOutputFields.dtd
  A.5.3 x3d-3.3-Web3dExtensionsPublic.dtd
  A.5.4 x3d-3.3-Web3dExtensionsPrivate.dtd

A.6 Version 4.0 DOCTYPE documents
  A.6.1 x3d-4.0.dtd
  A.6.2 x3d-4.0-InputOutputFields.dtd
  A.6.3 x3d-4.0-Web3dExtensionsPublic.dtd
  A.6.4 x3d-4.0-Web3dExtensionsPrivate.dtd

A.1.2 Introduction

An XML Document Type Definition (DTD), also referred to as a DOCTYPE, is a grammar that defines the syntax of an XML tagset XML.

The X3D DTD has sufficient expressive power to:

The X3D DTD does not have sufficient expressive power to:

EXAMPLE  Each of the following scene-graph fragments validate satisfactorily:

<Shape>
   <Sphere/>
   <Appearance>
      <!-- https://htmlcolorcodes.com/colors/off-white -->
      <Material DEF='MaterialOffWhite' diffuseColor='0.980392 0.976471 0.964706'/>
      <ImageTexture DEF='ImageCloudlessEarth' url='"earth-topo.png" "earth-topo.jpg"'/>
   </Appearance>
</Shape>

and

<Shape>
   <Appearance>
      <ImageTexture DEF='ImageCloudlessEarth' url='"earth-topo.png" "earth-topo.jpg"'/>
      <!-- https://htmlcolorcodes.com/colors/off-white -->
      <Material DEF='MaterialOffWhite' diffuseColor='0.980392 0.976471 0.964706'/>
   </Appearance>
   <Sphere/>
</Shape>

Current versions of X3D XML DOCTYPE files are maintained at X3DVALIDATION.

Additional capabilities for validation of field values are provided by X3D XML Schema, X3D Regular Expressions (regexes) X3DREGEX, X3D Schematron, SCHEMATRON.1, SCHEMATRON.2, and X3DSCHEMATRON.

NOTE  Additional information about X3D XML scene structure, allowed field values, data type restrictions, authoring hints, warnings, and errors can be found in X3D Tooltips X3DTOOLTIPS and X3D Unified Object Model X3DUOM. Validation assets are maintained in human-readable and machine-readable forms, in version control, and with corresponding documentation at X3DVALIDATION.

A.2 Version 3.0 DOCTYPE documents

A.2.1 x3d-3.0.dtd

x3d-3.0.dtd is the X3D DTD that validates model correctness for X3D version 3.0 content.

A.2.2 x3d-3.0-InputOutputFields.dtd

x3d-3.0-InputOutputFields.dtd extends the X3D version 3.0 DTD by also including fields with accessType inputOnly and outputOnly. Although X3D scene files cannot validly set values for any of these attributes, the DTD defines names and relationships of all fields and can be used by DTD-aware processing tools.

A.2.3 x3d-3.0-Web3dExtensionsPublic.dtd

x3d-3.0-Web3dExtensionsPublic.dtd extends the X3D version 4.0 DTD and can be used to contain approved extensions that have not yet been included in ISO/IEC 19775-1 X3D Architecture.

A.2.4 x3d-3.0-Web3dExtensionsPrivate.dtd

x3d-3.0-Web3dExtensionsPrivate.dtd extends the X3D version 4.0 DTD and can be used to contain X3D extensions that have not been approved but may exist for testing future development.

A.3 Version 3.1 DOCTYPE documents

A.3.1 x3d-3.1.dtd

x3d-3.1.dtd is the X3D DTD that validates model correctness for X3D version 3.1 content. Validation is backwards compatible with earlier versions of X3D models as well.

A.3.2 x3d-3.1-InputOutputFields.dtd

x3d-3.1-InputOutputFields.dtd extends the X3D version 3.1 DTD by also including fields with accessType inputOnly and outputOnly. Although X3D scene files cannot validly set values for any of these attributes, the DTD defines names and relationships of all fields and can be used by DTD-aware processing tools.

A.3.3 x3d-3.1-Web3dExtensionsPublic.dtd

x3d-3.1-Web3dExtensionsPublic.dtd extends the X3D version 4.0 DTD and can be used to contain approved extensions that have not yet been included in ISO/IEC 19775-1 X3D Architecture.

A.3.4 x3d-3.1-Web3dExtensionsPrivate.dtd

x3d-3.1-Web3dExtensionsPrivate.dtd extends the X3D version 4.0 DTD and can be used to contain X3D extensions that have not been approved but may exist for testing future development.

A.4 Version 3.2 DOCTYPE documents

A.4.1 x3d-3.2.dtd

x3d-3.2.dtd is the X3D DTD that validates model correctness for X3D version 3.2 content. Validation is backwards compatible with earlier versions of X3D models as well.

A.4.2 x3d-3.2-InputOutputFields.dtd

x3d-3.2-InputOutputFields.dtd extends the X3D version 3.2 DTD by also including fields with accessType inputOnly and outputOnly. Although X3D scene files cannot validly set values for any of these attributes, the DTD defines names and relationships of all fields and can be used by DTD-aware processing tools.

A.4.3 x3d-3.2-Web3dExtensionsPublic.dtd

x3d-3.2-Web3dExtensionsPublic.dtd extends the X3D version 4.0 DTD and can be used to contain approved extensions that have not yet been included in ISO/IEC 19775-1 X3D Architecture.

A.4.4 x3d-3.2-Web3dExtensionsPrivate.dtd

x3d-3.2-Web3dExtensionsPrivate.dtd extends the X3D version 4.0 DTD and can be used to contain X3D extensions that have not been approved but may exist for testing future development.

A.5 Version 3.3 DOCTYPE documents

A.5.1 x3d-3.3.dtd

x3d-3.3.dtd is the X3D DTD that validates model correctness for X3D version 3.3 content. Validation is backwards compatible with earlier versions of X3D models as well.

A.5.2 x3d-3.3-InputOutputFields.dtd

x3d-3.3-InputOutputFields.dtd extends the X3D version 3.3 DTD by also including fields with accessType inputOnly and outputOnly Although X3D scene files cannot validly set values for any of these attributes, the DTD defines names and relationships of all fields and can be used by DTD-aware processing tools.

A.5.3 x3d-3.3-Web3dExtensionsPublic.dtd

x3d-3.3-Web3dExtensionsPublic.dtd extends the X3D version 4.0 DTD and can be used to contain approved extensions that have not yet been included in ISO/IEC 19775-1 X3D Architecture.

A.5.4 x3d-3.3-Web3dExtensionsPrivate.dtd

x3d-3.3-Web3dExtensionsPrivate.dtd extends the X3D version 4.0 DTD and can be used to contain X3D extensions that have not been approved but may exist for testing future development.

A.6 Version 4.0 DOCTYPE documents

A.6.1 x3d-4.0.dtd

x3d-4.0.dtd is the X3D DTD that validates model correctness for X3D version 4.0 content. Validation is backwards compatible with earlier versions of X3D models as well, with one significant variation.

A containerField value defines the field relationship between a given node and its parent. X3D version 4 default containerField values were changed for all six X3dMetadataObject nodes (MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataSet, MetadataString). This change was applied to version 4.0 (and greater) of the X3D DTD and X3D Schema in order to facilitate more-readable construction of large metadata structures. No functional or naming changes to field interfaces were made in the X3D Architecture ISO/IEC 19775-1 X3D Architecture.

This change can affect X3D files defined using the XML encoding that depend on implicit definition of containerField values in Metadata nodes by the X3D XML DOCTYPE declaration. See X3D XML Schema, B.6.1 x3d-4.0.xsd for examples showing how legacy X3D versions 3.0-3.3 XML content that depends upon implicit containerField values may need to be modified for consistent definition as X3D version 4.0 XML and later.

A.6.2 x3d-4.0-InputOutputFields.dtd

x3d-4.0-InputOutputFields.dtd extends the X3D version 4.0 DTD by also including fields with accessType inputOnly and outputOnly Although X3D scene files cannot validly set values for any of these attributes, the DTD defines names and relationships of all fields and can be used by DTD-aware processing tools.

A.6.3 x3d-4.0-Web3dExtensionsPublic.dtd

x3d-4.0-Web3dExtensionsPublic.dtd extends the X3D version 4.0 DTD and can be used to contain approved extensions that have not yet been included in ISO/IEC 19775-1 X3D Architecture.

A.6.4 x3d-4.0-Web3dExtensionsPrivate.dtd

x3d-4.0-Web3dExtensionsPrivate.dtd extends the X3D version 4.0 DTD and can be used to contain X3D extensions that have not been approved but may exist for testing future development.

--- X3D separator bar ---