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

Annex B

(informative)

X3D XML Schema

(Updated using X3D Specifications: Schema and DOCTYPE Validation)

--- X3D separator bar ---

cube B.1 Topics and introduction

B.1.1 Topics

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

Table B.1 — Topics in this clause

B.1 Table of contents and introduction
  B.1.1 Topics
  B.1.2 Introduction
B.2 Version 3.0 schema
  B.2.1 x3d-3.0.xsd
  B.2.2 x3d-3.0-Web3dExtensionsPublic.xsd
  B.2.3 x3d-3.0-Web3dExtensionsPrivate.xsd
B.3 Version 3.1 schema
  B.3.1 x3d-3.1.xsd
  B.3.2 x3d-3.1-Web3dExtensionsPublic.xsd
  B.3.3 x3d-3.1-Web3dExtensionsPrivate.xsd
B.4 Version 3.2 schema
  B.4.1 x3d-3.2.xsd
  B.4.2 x3d-3.2-Web3dExtensionsPublic.xsd
  B.4.3 x3d-3.2-Web3dExtensionsPrivate.xsd
B.5 Version 3.3 schema
  B.5.1 x3d-3.3.xsd
  B.5.2 x3d-3.3-Web3dExtensionsPublic.xsd
  B.5.3 x3d-3.3-Web3dExtensionsPrivate.xsd

B.1.2 Introduction

An XML Schema defines the syntax of an XML tagset using an XML-based grammar as specified in [XML_SCHEMA]. Further information about XML Schema design is found in [XML_SCHEMA_PRIMER].

The X3D Schema has sufficient expressive power to:

The X3D Schema does not have sufficient expressive power to:

Editors note: adding explanatory excerpts from X3D XML Schema source seems like unnecessary detail.

Current versions of X3D XML Schema files are maintained at [X3DVALIDATION].

Additional capabilities for validation of field values are provided by XML Document Type Definition (DTD), X3D Regular Expressions (regexes) [X3DREGEX], and X3D Schematron [SCHEMATRON.1] [SCHEMATRON.2] [X3DSCHEMATRON].

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].

cube B.2 Version 3.0 schema

B.2.1 x3d-3.0.xsd

x3d-3.0.xsd is the X3D schema file that validates model correctness for X3D version 3.0 content.

<!-- prior source document deleted for readability -->

B.2.2 x3d-3.0-Web3dExtensionsPublic.xsd

x3d-3.0-Web3dExtensionsPublic.xsd extends the X3D version 3.0 schema. It is the public X3D schema file for X3D version 3.0 that can will be used to contain approved extensions that have not yet been included in Part 1 of ISO/IEC 19775. The form of the public X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

B.2.3 x3d-3.0-Web3dExtensionsPrivate.xsd

x3d-3.0-Web3dExtensionsPrivate.xsd extends the X3D version 3.0 schema. It is the private X3D schema file for X3D version 3.0 that can will be used to contain extensions that have not been formally approved but may exist for testing future development. The form of the public X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

cube B.3 Version 3.1 schema

B.3.1 x3d-3.1.xsd

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

<!-- prior source document deleted for readability -->

B.3.2 x3d-3.1-Web3dExtensionsPublic.xsd

x3d-3.1-Web3dExtensionsPublic.xsd extends the X3D version 3.1 schema. It is the public X3D schema file for X3D version 3.1 that can will be used to contain approved extensions that have not yet been included in Part 1 of ISO/IEC 19775. The form of the public X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

B.3.3 x3d-3.1-Web3dExtensionsPrivate.xsd

x3d-3.1-Web3dExtensionsPrivate.xsd extends the X3D version 3.0 schema. It is the private X3D schema file for X3D version 3.1 that can will be used to contain extensions that have not been formally approved but may exist for testing future development. The form of the private X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

cube B.4 Version 3.2 schema

B.4.1 x3d-3.2.xsd

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

<!-- prior source document deleted for readability -->

B.4.2 x3d-3.2-Web3dExtensionsPublic.xsd

x3d-3.2-Web3dExtensionsPublic.xsd extends the X3D version 3.2 schema. It is the public X3D schema file for X3D version 3.2 that can will be used to contain approved extensions that have not yet been included in Part 1 of ISO/IEC 19775. The form of the public X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

B.4.3 x3d-3.2-Web3dExtensionsPrivate.xsd

x3d-3.2-Web3dExtensionsPrivate.xsd extends the X3D version 3.2 schema. It is the private X3D schema file for X3D version 3.2 that can will be used to contain extensions that have not been formally approved but may exist for testing future development. The form of the private X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

cubeB.5 Version 3.3 schema

B.5.1 x3d-3.3.xsd

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

<!-- prior source document deleted for readability -->

B.5.2 x3d-3.3-Web3dExtensionsPublic.xsd

x3d-3.3-Web3dExtensionsPublic.xsd extends the X3D version 3.3 schema. It is the public X3D schema file for X3D version 3.3 that can will be used to contain approved extensions that have not yet been included in Part 1 of ISO/IEC 19775. The form of the public X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

B.5.3 x3d-3.3-Web3dExtensionsPrivate.xsd

x3d-3.3-Web3dExtensionsPrivate.xsd extends the X3D version 3.3 schema. It is the private X3D schema file for X3D version 3.3 that can will be used to contain extensions that have not been formally approved but may exist for testing future development. The form of the private X3D schema file is depicted below.

<!-- prior source document deleted for readability -->

cubeB.6 Version 4.0 schema

B.6.1 x3d-4.0.xsd

x3d-4.0.xsd is the X3D schema file 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 [I19775-1].

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 Schema declaration. The following examples show how legacy X3D3 XML content that depends upon implicit containerField values may need to be modified for consistent definition as X3D4 XML.

Editors note: the following example excerpts can be found at WorldInfoExampleMetadataSetX3D3.x3d and WorldInfoExampleMetadataSetX3D4.x3d

EXAMPLE 

Table B.2 — Equivalent representations of a metadata collection

X3D version 3.0-3.3 or version 4.0 content using explicit containerField values
<WorldInfo title='WorldInfoExampleMetadataSetX3D explicit'>
    <MetadataSet containerField='metadata' name='birthday'
                        reference='https://www.archives.gov/legislative/features/washington'>
        <MetadataString containerField='metadata' name='calendar' value='"Julian"'
                        reference='this node describes nature of parent node, and is not intended as a data value'/>
        <MetadataString containerField='value' name='name' value='"George" "Washington"'/>
        <MetadataInteger containerField='value' name='day' value='11'/>
        <MetadataInteger containerField='value' name='month' value='2'/>
        <MetadataInteger containerField='value' name='year' value='1731'/>
        <MetadataString containerField='value' name='birthplace' value='"Popes Creek" "Virginia"'/>
    </MetadataSet>
</WorldInfo>
X3D version 3.0-3.3 content using default containerField values
<WorldInfo title='WorldInfoExampleMetadataSetX3D3.x3d'>
    <MetadataSet name='birthday'
                        reference='https://www.archives.gov/legislative/features/washington'>
        <MetadataString name='calendar' value='"Julian"'
                        reference='this node describes nature of parent node, and is not intended as a data value'/>
        <MetadataString containerField='value' name='name' value='"George" "Washington"'/>
        <MetadataInteger containerField='value' name='day' value='11'/>
        <MetadataInteger containerField='value' name='month' value='2'/>
        <MetadataInteger containerField='value' name='year' value='1731'/>
        <MetadataString containerField='value' name='birthplace' value='"Popes Creek" "Virginia"'/>
    </MetadataSet>
</WorldInfo>
X3D version 4.0 content using default containerField values
<WorldInfo title='WorldInfoExampleMetadataSetX3D4.x3d Example Scene'>
    <MetadataSet containerField='metadata' name='birthday'
                        reference='https://www.archives.gov/legislative/features/washington'>
        <MetadataString containerField='metadata' name='calendar' value='"Julian"'
                        reference='this node describes nature of parent node, and is not intended as a data value'/>
        <MetadataString name='name' value='"George" "Washington"'/>
        <MetadataInteger name='day' value='11'/>
        <MetadataInteger name='month' value='2'/>
        <MetadataInteger name='year' value='1731'/>
        <MetadataString name='birthplace' value='"Popes Creek" "Virginia"'/>
    </MetadataSet>
</WorldInfo>

The form of the public X3D schema file is depicted below.

Editors note: copying source document excerpts here, even if just for latest version, seems superfluous.

B.6.2 x3d-4.0-Web3dExtensionsPublic.xsd

x3d-4.0-Web3dExtensionsPublic.xsd extends the X3D version 4.0 schema. It is the public X3D schema file for X3D version 4.0 that can will be used to contain approved extensions that have not yet been included in Part 1 of ISO/IEC 19775. The form of the public X3D schema file is depicted below.

Editors note: copying source document excerpts here, even if just for latest version, seems superfluous.

B.6.3 x3d-4.0-Web3dExtensionsPrivate.xsd

x3d-4.0-Web3dExtensionsPrivate.xsd extends the X3D version 4.0 schema. It is the private X3D schema file for X3D version 4.0 that can will be used to contain extensions that have not been formally approved but may exist for testing future development. The form of the private X3D schema file is depicted below.

Editors note: copying source document excerpts here, even if just for latest version, seems superfluous.

--- X3D separator bar ---