<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.3//EN" "https://www.web3d.org/specifications/x3d-3.3.dtd">
<X3D profile='Interchange' version='3.3 xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation =' https://www.web3d.org/specifications/x3d-3.3.xsd '>
<head>
<meta name='titlecontent='ColorPerVertexExamples.x3d'/>
<meta name='descriptioncontent='Geometry Polygons Nodes: Color, Coordinate, IndexedFaceSet, IndexedLineSet, PointSet'/>
<meta name='creatorcontent='Don Brutzman'/>
<meta name='createdcontent='5 September 2005'/>
<meta name='modifiedcontent='11 May 2021'/>
<meta name='Imagecontent='ColorPerVertexExamples.png'/>
<meta name=' TODO content=' Blender import problems '/>
<meta name='Imagecontent='ColorPerVertexExamplesBlender.png'/>
<meta name=' TODO content=' Xj3D rendering problems '/>
<meta name='Imagecontent='ColorPerVertexExamplesXj3D.png'/>
<meta name='referencecontent=' https://www.web3d.org/x3d/tooltips/X3dTooltips.html#IndexedFaceSet '/>
<meta name='referencecontent=' https://www.web3d.org/x3d/tooltips/X3dTooltips.html#IndexedLineSet '/>
<meta name='referencecontent=' https://www.web3d.org/x3d/tooltips/X3dTooltips.html#Coordinate '/>
<meta name='referencecontent=' https://www.web3d.org/x3d/tooltips/X3dTooltips.html#Color '/>
<meta name='rightscontent='Copyright (c) 2005, Daly Realism and Don Brutzman'/>
<meta name='identifiercontent=' https://X3dGraphics.com/examples/X3dForWebAuthors/Chapter06GeometryPointsLinesPolygons/ColorPerVertexExamples.x3d '/>
<meta name='generatorcontent='X3D-Edit 3.3, https://savage.nps.edu/X3D-Edit'/>
<meta name='licensecontent=' ../license.html'/>
</head>
<!--

Index for DEF nodes : FourColors, FourColorsRGBA, FourPoints

Index for Viewpoint image : Viewpoint_1
-->
<Scene>
<WorldInfo title='ColorPerVertexExamples.x3d'/>
<Viewpoint description='ColorPerVertex Examplesposition='0 0 6'/>
<Background groundColor='0.1 0.1 0.1skyColor='0.1 0.1 0.1'/>
<Transform translation='-0.5 0 0'>
<Transform translation='-3 0 0'>
<Shape>
<!-- Default settings: colorPerVertex='true' and solid='true' (single-sided polygon) -->
<IndexedFaceSet colorIndex='0 1 2 3 0 -1coordIndex='0 1 2 3 0 -1'>
<Coordinate DEF='FourPointspoint='0 0 0 1 0 0 1 1 0 0 1 0'/>
<Color DEF='FourColorscolor='1 0 0 0 1 0 0 0 1 0.8 0.8 0.8'/>
</IndexedFaceSet>
</Shape>
</Transform>
<Transform translation='-1 0 0'>
<Shape>
<!-- Non-default settings: colorPerVertex='false' and solid='false' (double-sided polygon) -->
<IndexedFaceSet colorPerVertex='falsesolid='falsecolorIndex='2coordIndex='0 1 2 3 0 -1'>
<!-- Note that only 4 points are needed to create a 4-vertex polygon. -->
<Coordinate USE='FourPoints'/>
<ColorRGBA DEF='FourColorsRGBAcolor='1 0 0 1 0 1 0 1 0 0 1 0.5 0.8 0.8 0.8 0'/>
</IndexedFaceSet>
</Shape>
</Transform>
<Transform translation='1 0 0'>
<Shape>
<!-- Student TODO: try different color indices. -->
<IndexedLineSet colorIndex='0 1 2 3 0 -1coordIndex='0 1 2 3 0 -1'>
<Coordinate USE='FourPoints'/>
<Color USE='FourColors'/>
</IndexedLineSet>
</Shape>
</Transform>
<Transform translation='3 0 0'>
<Shape>
<!-- Note that 5 points are needed to create 4 complete line segments. -->
<IndexedLineSet colorPerVertex='falsecolorIndex='0coordIndex='0 1 2 3 0 -1'>
<Coordinate USE='FourPoints'/>
<Color USE='FourColors'/>
</IndexedLineSet>
</Shape>
</Transform>
</Transform>
</Scene>
</X3D>
<!--

Index for DEF nodes : FourColors, FourColorsRGBA, FourPoints

Index for Viewpoint image : Viewpoint_1
-->

<!-- Color key: <X3dNode DEF='idName' field='value'/> matches <XmlElement DEF='idName' attribute='value'/>
(Light blue background: behavior node) (Grey background: inserted documentation) (Magenta background: X3D Extensibility)
-->

<!-- For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources and X3D Scene Authoring Hints. -->