This schema describes a XML language to build a world model used for Augmented Reality and Ubiquitous Computing research projects at the Vienna University of Technology. It provides the structures to describe geometry and spatial relations between buildings and rooms contained within building. in addition to that it allows to store locations of markers used for optical tracking within the building.
Its is also designed to be very extensible. A hierarchy of types defines the basic semantics of elements. Elements then further specialize these to provide more application specific information. Therefore additional content can be embedded in structures already built with this format.
This should be a basis for discussion and extension towards a larger schema for our world model. Currently we plan to store the data for Signpost 2.0 and the OCAR application in this format. Please contact Gerhard Reitmayr <reitmayr@ims.tuwien.ac.at> with any remarks you have.
Version 2.1 - 18.1.2003
<simpleType name="UnitSphereValue">
<restriction base="xs:double">
<maxInclusive value="1" fixed="false"/>
<minInclusive value="-1" fixed="false"/>
</restriction>
</simpleType>
<simpleType name="DoubleList"> <list itemType="xs:double"/> </simpleType>
<simpleType name="IntegerList"> <list itemType="xs:integer"/> </simpleType>
<simpleType name="UnitSphereValueList"> <list itemType="xs:double"/> </simpleType>
<simpleType name="Vec3">
<restriction base="DoubleList">
<length value="3" fixed="false"/>
</restriction>
</simpleType>
<simpleType name="Quaternion">
<restriction base="UnitSphereValueList">
<length value="4" fixed="false"/>
</restriction>
</simpleType>
<complexType name="AnnotationType" mixed="false" abstract="false">
<complexContent>
<extension base="xs:anyType"/>
</complexContent>
</complexType>
<complexType name="RepresentationType" mixed="false" abstract="false">
<choice minOccurs="1" maxOccurs="1">
<sequence minOccurs="1" maxOccurs="1">
<element name="Vertex" maxOccurs="unbounded" minOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<attribute name="position" type="Vec3" use="optional">
</attribute>
<attribute name="id"/>
</complexType>
</element>
<element name="Polygon" minOccurs="0" maxOccurs="unbounded" nillable="false">
<complexType mixed="false" abstract="false">
<attribute name="vertices" type="IntegerList" use="required">
</attribute>
<attribute name="type" use="required">
<simpleType>
<restriction base="xs:string">
<enumeration value="wall"/>
<enumeration value="floor"/>
<enumeration value="portal"/>
<enumeration value="ceiling"/>
<enumeration value="special"/>
</restriction>
</simpleType>
</attribute>
<attribute name="name" type="xs:NCName" use="optional">
</attribute>
</complexType>
</element>
</sequence>
</choice>
</complexType>
<complexType name="PoseType" mixed="false" abstract="false">
<choice minOccurs="1" maxOccurs="1">
<element name="Transformation" minOccurs="1" maxOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<attribute name="translation" type="Vec3" use="optional" default="0 0 0">
</attribute>
<attribute name="rotation" type="DoubleList" use="optional" default="0 0 1 0">
</attribute>
<attribute name="rotationType" use="optional" default="axisangle">
<simpleType>
<restriction base="xs:string">
<enumeration value="axisangle"/>
<enumeration value="quaternion"/>
<enumeration value="matrix"/>
<enumeration value="euler"/>
</restriction>
</simpleType>
</attribute>
<attribute name="scale" type="Vec3" use="optional" default="1 1 1">
</attribute>
</complexType>
</element>
<element name="MatrixTransform" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<attribute name="matrix" use="optional">
<simpleType>
<restriction base="DoubleList">
<length value="16" fixed="false"/>
</restriction>
</simpleType>
</attribute>
</complexType>
</element>
</choice>
</complexType>
<complexType name="ObjectType" mixed="false" abstract="false">
<sequence minOccurs="1" maxOccurs="1">
<element name="annotation" type="AnnotationType" minOccurs="0" maxOccurs="1" nillable="false"/>
</sequence>
<attribute name="id" type="xs:ID" use="optional">
</attribute>
</complexType>
Important conceps get codified into a type system. Actual instance types are derived from one of these main types and can extend these or other instances types. This allows to have application dependend extensions to the main types.
At the same time, every instance type carries an attribute baseType that identifies the main type it is derived from. This allows applications that do not know anything about the instance type to revert to some default behaviour.
<complexType name="SpatialObjectType" mixed="false" abstract="false">
<complexContent>
<extension base="ObjectType">
<sequence minOccurs="1" maxOccurs="1">
<element name="pose" type="PoseType" minOccurs="0" maxOccurs="1" nillable="false"/>
<element name="representation" type="RepresentationType" minOccurs="0" nillable="false" abstract="false"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexType name="SpatialContainerType" mixed="false" abstract="false">
<complexContent>
<extension base="SpatialObjectType">
<sequence minOccurs="1" maxOccurs="1">
<element name="children" minOccurs="0" maxOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<sequence minOccurs="0" maxOccurs="unbounded">
<element ref="Object" minOccurs="1" maxOccurs="1" nillable="false"/>
</sequence>
</complexType>
</element>
</sequence>
</extension>
</complexContent>
</complexType>
<element name="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="ObjectType">
<attribute name="baseType" type="xs:NCName" fixed="ObjectType" use="optional">
</attribute>
</extension>
</complexContent>
</complexType>
</element>
<element name="SpatialObject" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialObjectType">
<attribute name="baseType" type="xs:NCName" fixed="SpatialObjectType" use="optional"/>
</extension>
</complexContent>
</complexType>
</element>
<element name="SpatialContainer" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialContainerType">
<attribute name="baseType" type="xs:NCName" fixed="SpatialContainerType" use="optional"/>
</extension>
</complexContent>
</complexType>
</element>
<element name="Building" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialContainerType">
<attribute name="baseType" type="xs:NCName" fixed="SpatialContainerType" use="optional"/>
</extension>
</complexContent>
</complexType>
</element>
<element name="Room" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialContainerType">
<sequence minOccurs="1" maxOccurs="1">
<element name="portals" minOccurs="0" maxOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<sequence minOccurs="1" maxOccurs="1">
<element name="Portal" maxOccurs="unbounded" minOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<attribute name="room" type="xs:string" use="required">
</attribute>
<attribute name="polygon" type="xs:string" use="required">
</attribute>
<attribute name="polygonnb" type="xs:string" use="optional">
</attribute>
</complexType>
</element>
</sequence>
</complexType>
</element>
</sequence>
<attribute name="baseType" type="xs:NCName" fixed="SpatialContainerType"/>
</extension>
</complexContent>
</complexType>
</element>
<element name="ARToolkitMarker" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialObjectType">
<attribute name="number" type="xs:integer" use="required"/>
<attribute name="baseType" type="xs:NCName" fixed="SpatialObjectType"/>
</extension>
</complexContent>
</complexType>
</element>
<element name="Waypoint" substitutionGroup="Object" nillable="false" abstract="false">
<complexType mixed="false" abstract="false">
<complexContent>
<extension base="SpatialObjectType">
<sequence minOccurs="1" maxOccurs="1">
<element name="neighbors" minOccurs="0" maxOccurs="1" nillable="false">
<complexType mixed="false" abstract="false">
<attribute name="neighbors" type="xs:string" use="required">
</attribute>
</complexType>
</element>
</sequence>
<attribute name="baseType" type="xs:NCName" fixed="SpatialObjectType"/>
</extension>
</complexContent>
</complexType>
</element>
some type definitions for attributes
complex types for actual element declarations. we use these types to document the derivation hierarchy of elements and the objects they represent.
the following types define base types for parts of objects.
The following types represent the actual object hierarchy, describing the ontology of our format
the declarations of actual elements used. these define the names and more detailed content models depending on the types defined in above section