Difference between revisions of "Appearance"

From Web3D.org
Jump to: navigation, search
Line 1: Line 1:
 
* [[Node Reference]]
 
* [[Node Reference]]
 
==Appearance==
 
==Appearance==
 +
 +
Specification Link: [http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/shape.html#Appearance Appearance]
  
 
<pre>
 
<pre>
Line 14: Line 16:
 
</pre>
 
</pre>
  
<p>The Appearance node specifies the visual properties of geometry. The value for each of the fields in this node may be <code>NULL</code>. However, if the field is non-<code>NULL</code>, it shall contain one node of the appropriate type.</p>
+
==DTD Validation==
  
<p>The <i>material</i> field, if specified, shall contain a Material node. If the <i>material</i> field is <code>NULL</code> or unspecified, lighting is off (all lights are ignored during rendering of the object that references this Appearance) and the unlit object colour is (1, 1, 1). Details of the X3D lighting model are in 17 Lighting component.</p>
+
===Children===
  
<p>The <i>texture</i> field, if specified, shall contain one of the various types of texture nodes (see: Texturing component). If the texture node is <code>NULL</code> or the <i>texture</i> field is unspecified, the object that references this Appearance is not textured.</p>
+
Children must appear as follows:
  
<p>The <i>textureTransform</i> field, if specified, shall contain a TextureTransform node as defined in 18.4.8 TextureTransform. If the <i>textureTransform</i> is <code>NULL</code> or unspecified, the <i>textureTransform</i> field has no effect.</p>
+
# A single, optional IS.
 +
# A single, optional node derived from X3DMetadataObject for the ''metadata'' field.
 +
# TBD
  
<p>The <i>lineProperties</i> field, if specified, shall contain a LineProperties node as specified in 12.4.3 LineProperties. If <i>lineProperties</i> is <code>NULL</code> or unspecified, the <i>lineProperties</i> field has no effect.</p>
+
===Attributes===
  
<p>The <i>fillProperties</i> field, if specified, shall contain a FillProperties node as specified in 12.4.2 FillProperties. If <i>fillProperties</i> is <code>NULL</code> or unspecified, the <i>fillProperties</i> field has no effect.</p>
+
N/A.
==Example==
+
This example shows a simple appearance containing a red material.
+
<pre>
+
#X3D V3.0 utf8
+
  
PROFILE Interchange
+
==Schema Validation==
 +
 
 +
===Children===
 +
 
 +
Children must appear as follows:
 +
 
 +
# A single, optional IS.
 +
# A single, optional node derived from X3DMetadataObject for the ''metadata'' field.
 +
# TBD.
 +
 
 +
===Attributes===
 +
 
 +
N/A
 +
 
 +
==Schematron Validation==
 +
 
 +
TBD
  
Shape {
 
  appearance Appearance {
 
      material Material {
 
        diffuseColor 1 0 0
 
      }
 
  }
 
  geometry Box {}
 
}
 
</pre>
 
  
 
* [[Node Reference]]
 
* [[Node Reference]]

Revision as of 12:54, 18 April 2015

Appearance

Specification Link: Appearance

Appearance : X3DAppearanceNode { 
  SFNode [in,out] fillProperties   NULL [FillProperties]
  SFNode [in,out] lineProperties   NULL [LineProperties]
  SFNode [in,out] material         NULL [X3DMaterialNode]
  SFNode [in,out] metadata         NULL [X3DMetadataObject]
  MFNode [in,out] shaders          []   [X3DShaderNode]
  SFNode [in,out] texture          NULL [X3DTextureNode]
  SFNode [in,out] textureTransform NULL [X3DTextureTransformNode]
}

DTD Validation

Children

Children must appear as follows:

  1. A single, optional IS.
  2. A single, optional node derived from X3DMetadataObject for the metadata field.
  3. TBD

Attributes

N/A.

Schema Validation

Children

Children must appear as follows:

  1. A single, optional IS.
  2. A single, optional node derived from X3DMetadataObject for the metadata field.
  3. TBD.

Attributes

N/A

Schematron Validation

TBD