<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.1//EN" "https://www.web3d.org/specifications/x3d-3.1.dtd">
<X3D profile='Immersive'  version='3.1 xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation =' https://www.web3d.org/specifications/x3d-3.1.xsd ' >
<head>
<meta name='titlecontent=' CadGeometryPrototypes.x3d '/>
<meta name='descriptioncontent='This scene provides tool developers with X3D Amendment 1 CAD Component node prototypes, providing backwards compatibility with VRML97 and X3D v3.0.'/>
<meta name='creatorcontent='Travis Rauch, Alan Shaffer, Mounir Sidhom, Patrick Sullivan and Don Brutzman'/>
<meta name='createdcontent='28 April 2005'/>
<meta name='modifiedcontent='20 October 2019'/>
<meta name=' warning content=' Do not use these prototypes in an up-to-date X3D browser that already provides CAD support. '/>
<meta name='informationcontent='Recommended practice: avoid using these prototypes, instead use native definitions for CAD nodes using an up-to-date X3D browser.'/>
<meta name='informationcontent='These scenes are not intended for regular authoring - use X3D v3.2 CAD component instead. Example scenes using these prototypes do not get support for making embdedded metadata values visible at run time, though metadata can certainly be saved in the scene file OK.'/>
<meta name='referencecontent=' CadGeometryExternPrototypes.x3d '/>
<meta name='referencecontent=' https://www.web3d.org/files/specifications/19775-1/V3.3/Part01/components/CADGeometry.html '/>
<meta name='referencecontent=' https://www.web3d.org/files/specifications/19775-1/V3.3/Part01/CADInterchange.html '/>
<meta name='subjectcontent='CADAssembly CADFace CADLayer CADPart IndexedQuadSet QuadSet'/>
<meta name='identifiercontent=' https://www.web3d.org/x3d/content/examples/Basic/CAD/CadGeometryPrototypes.x3d '/>
<meta name='generatorcontent='X3D-Edit 3.3, https://savage.nps.edu/X3D-Edit'/>
<meta name='licensecontent=' ../license.html'/>
</head>
<!-- -->
<Scene>
<!-- =========================================== -->
<WorldInfo title='CadGeometryPrototypes.x3d'/>
<ProtoDeclare name='IndexedQuadSetappinfo='The IndexedQuadSet node represents a 3D shape composed of a collection of individual quadrilaterals (quads). IndexedQuadSet uses the indices in its index field to specify the vertices of each quad from the coord field. Each quad is formed from a set of four vertices of the Coordinate node identified by four consecutive indices from the index field If the index field does not contain a multiple of four coordinate values the remaining vertices shall be ignored.'  documentation=' https://www.web3d.org/x3d/specifications/ISO-IEC-19775-Amendment1-PDAM-X3DAbstractSpecification/Part01/components/CADGeometry.html#IndexedQuadSet ' >
<ProtoInterface>
<field name='set_indextype='MFInt32accessType='inputOnly'
 appinfo='range [0..∞) or -1' >
<!-- No specific initialization value -->
</field>
<field name='attribtype='MFNodeaccessType='inputOutput'
 appinfo='[X3DVertexAttributeNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='colortype='SFNodeaccessType='inputOutput'
 appinfo='[X3DColorNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='coordtype='SFNodeaccessType='inputOutput'
 appinfo='[X3DCoordinateNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='fogCoordtype='SFNodeaccessType='inputOutput'
 appinfo='[FogCoordinate]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='normaltype='SFNodeaccessType='inputOutput'
 appinfo='[X3DNormalNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='texCoordtype='SFNodeaccessType='inputOutput'
 appinfo='[X3DTextureCoordinateNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='ccwtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='colorPerVertextype='SFBoolvalue='trueaccessType='initializeOnly'
 appinfo='colorPerVertex ignored in IndexedQuadSet, and always treated as true' />

<field name='normalPerVertextype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='solidtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='indextype='MFInt32accessType='initializeOnly'
 appinfo='range [0..∞) or -1' >
<!-- No specific initialization value -->
</field>
<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<IndexedFaceSet DEF='RenderedIQS'>
<IS>
<connect nodeField='attribprotoField='attrib'/>
<connect nodeField='colorprotoField='color'/>
<connect nodeField='colorPerVertexprotoField='colorPerVertex'/>
<connect nodeField='coordprotoField='coord'/>
<connect nodeField='fogCoordprotoField='fogCoord'/>
<connect nodeField='normalprotoField='normal'/>
<connect nodeField='texCoordprotoField='texCoord'/>
<connect nodeField='ccwprotoField='ccw'/>
<connect nodeField='normalPerVertexprotoField='normalPerVertex'/>
<connect nodeField='solidprotoField='solid'/>
</IS>
</IndexedFaceSet>
<!-- Initial node in the PROTO body is actual node type, and the only node rendered. Remaining ProtoBody nodes not rendered -->
<Group DEF='UnrenderedIQS'>
<Script DEF='IndexedQuadSetToIndexedFaceSetdirectOutput='true'>
<field name='indextype='MFInt32accessType='initializeOnly'/>
<field name='set_indextype='MFInt32accessType='inputOnly'/>
<field name='renderedIQStype='SFNodeaccessType='initializeOnly'>
<IndexedFaceSet USE=' RenderedIQS'/>
</field>
<field name='localTraceEnabledtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='coordIndexNewtype='MFInt32accessType='initializeOnly'>
<!-- constructed during initialization -->
</field>
<IS>
<connect nodeField='indexprotoField='index'/>
<connect nodeField='set_indexprotoField='set_index'/>
</IS>
<![CDATA[
            
ecmascript:

function initialize()
{
	//colorPerVertex ignored in IndexedQuadSet, and always treated as "true"
	RenderedIQS.colorPerVertex = true;

	// index is an array of quad indices. The ordering of
	// the vertices is ccw (counter-clockwise).

	// ensure legal index values
	for (ii=0; ii <= index.length-1; ii++)
	{
	  if (index[ii] < -1)
	  {
		alwaysPrint ('error, index[' + ii + ']=' + index[ii] + ' is illegal value');
		return;
	  }
	}
	tracePrint ('index.length=' + index.length);
	tracePrint ('index=' + index);

	if (index.length < 4)
	{
		alwaysPrint ('warning, index.length=' + index.length + ' insufficient to construct a quad, IQS ignored');
		return;
	}

	coordIndexNew = new MFInt32 ();

	// ii walks through index array,
	// goal is to initialize coordIndexNew list to match quads
	for (ii=0; ii <= index.length-1; ii+=4)
	{
		if ((index[ii]   == index[ii+1]) || (index[ii]   == index[ii+2]) || (index[ii] == index[ii+3]) ||
		    (index[ii+1] == index[ii+2]) || (index[ii+1] == index[ii+3]) ||
		    (index[ii+2] == index[ii+3]))
		{
			alwaysPrint ('index=' + index);
			alwaysPrint ('error, pair of equal indices in quad');
			return;
		}

		if (index[ii] >= 0)
		{
			// add another quad from latest 4 points of fan set to IQS
			// order is ccw, i.e. in correct halfplane direction
			// note: there is an implicit "malloc" here for the'length' element of the array
			coordIndexNew [coordIndexNew.length] = index[ii];
			coordIndexNew [coordIndexNew.length] = index[ii+1];
			coordIndexNew [coordIndexNew.length] = index[ii+2];
			coordIndexNew [coordIndexNew.length] = index[ii+3];
			coordIndexNew [coordIndexNew.length] = -1;
		}

		if (index.length % 4 != 0) {
			alwaysPrint ('error, index field does not contain a multiple of four coordinate values.');
			alwaysPrint ('The remaining vertices shall be ignored');
			return;
		}

	  // incremental trace of array being built
	  tracePrint ('coordIndexNew=' + coordIndexNew);
	}
	renderedIQS.set_coordIndex = coordIndexNew;
	tracePrint ('renderedIQS.coordIndex=' + renderedIQS.coordIndex);
	// match colorIndex if any Color node exists
//	if (nodesHolder.color)
//	{
//	  if (nodesHolder.color.color.length > 0)
//	  {
		//  Could implement color count check here
//	  }
//	}

	// no need to set colorIndex since indexedFaceSet semantics handles this
}
function set_index (value, timestamp)
{
	index = value;
	initialize ();
}
function tracePrint(outputString)
{
    if (localTraceEnabled)
	  Browser.println ('[IndexedQuadSet]' + outputString);
}
function alwaysPrint(outputString)
{
	Browser.println ('[IndexedQuadSet]' + outputString);
}

          
]]>
</Script>
<Group>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
</Group>
</Group>
</ProtoBody>
</ProtoDeclare>
<!-- =========================================== -->
<ProtoDeclare name='QuadSetappinfo='The QuadSet node represents a 3D shape that represents a collection of individual planar quadrilaterals. The coord field contains a Coordinate node that defines the 3D vertices that define the quad. Each quad is formed from a consecutive set of four vertices of the coordinate node. If the coordinate node does not contain a multiple of four coordinate values the remaining vertices shall be ignored.'  documentation=' https://www.web3d.org/x3d/specifications/ISO-IEC-19775-Amendment1-PDAM-X3DAbstractSpecification/Part01/components/CadGeometry.html#QuadSet ' >
<ProtoInterface>
<field name='attribtype='MFNodeaccessType='inputOutput'
 appinfo='[X3DVertexAttributeNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='colortype='SFNodeaccessType='inputOutput'
 appinfo='[X3DColorNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='coordtype='SFNodeaccessType='inputOutput'
 appinfo='[X3DCoordinateNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='fogCoordtype='SFNodeaccessType='inputOutput'
 appinfo='[FogCoordinate]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='normaltype='SFNodeaccessType='inputOutput'
 appinfo='[X3DNormalNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='texCoordtype='SFNodeaccessType='inputOutput'
 appinfo='[X3DTextureCoordinateNode]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='ccwtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='colorPerVertextype='SFBoolvalue='trueaccessType='initializeOnly'
 appinfo='colorPerVertex ignored in QuadSet, and always treated as true' />

<field name='normalPerVertextype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='solidtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<IndexedFaceSet DEF='RenderedQS'>
<IS>
<connect nodeField='attribprotoField='attrib'/>
<connect nodeField='colorprotoField='color'/>
<connect nodeField='colorPerVertexprotoField='colorPerVertex'/>
<connect nodeField='coordprotoField='coord'/>
<connect nodeField='fogCoordprotoField='fogCoord'/>
<connect nodeField='normalprotoField='normal'/>
<connect nodeField='texCoordprotoField='texCoord'/>
<connect nodeField='ccwprotoField='ccw'/>
<connect nodeField='normalPerVertexprotoField='normalPerVertex'/>
<connect nodeField='solidprotoField='solid'/>
</IS>
</IndexedFaceSet>
<!-- Initial node in the PROTO body is actual node type, and the only node rendered. Remaining ProtoBody nodes not rendered -->
<Group DEF='UnrenderedQS'>
<Script DEF='QuadSetToIndexedFaceSetdirectOutput='true'>
<field name='indextype='MFInt32accessType='initializeOnly'>
<!-- initialized in ecmascript -->
</field>
<field name='set_indextype='MFInt32accessType='inputOnly'/>
<field name='renderedQStype='SFNodeaccessType='initializeOnly'>
<IndexedFaceSet USE=' RenderedQS'/>
</field>
<field name='localTraceEnabledtype='SFBoolvalue='trueaccessType='initializeOnly'/>
<field name='coordIndexNewtype='MFInt32accessType='initializeOnly'>
<!-- constructed during initialization -->
</field>
<![CDATA[
            
ecmascript:

function initialize()
{
	//colorPerVertex ignored in QuadSet, and always treated as "true"
	RenderedQS.colorPerVertex = true;

	// calculate index value from QuadSet coord values
	if (renderedQS.coord)
	{
		numberOfCoordinatePoints = renderedQS.coord.point.length;
	}
	else
	{
		tracePrint ('no Coordinate node found');
		return;
	}
	if (numberOfCoordinatePoints < 4)
	{
		alwaysPrint ('warning, numberOfCoordinatePoints=' + numberOfCoordinatePoints + ' insufficient to construct a quad, QuadSet ignored');
		return;
	}

	coordIndexNew = new MFInt32 ();

	// ii walks through index array,
	// goal is to initialize coordIndexNew list to match quads
	for (ii=0; ii <= numberOfCoordinatePoints-1; ii+=4)
	{
		// check if at least 4 vertices remaining to build a quad
		if ((numberOfCoordinatePoints - ii) < 4)
		{
			alwaysPrint ('error, index field does not contain a multiple' +
' of four coordinate values.');
			alwaysPrint ('The remaining vertices shall be ignored');
			return;
		}

		if ((index[ii]   == index[ii+1]) || (index[ii]   == index[ii+2]) || (index[ii] == index[ii+3]) ||
		    (index[ii+1] == index[ii+2]) || (index[ii+1] == index[ii+3]) ||
		    (index[ii+2] == index[ii+3]))
		{
			alwaysPrint ('index=' + index);
			alwaysPrint ('error, pair of equal indices in quad');
			return;
		}

		if (index[ii] >= 0)
		{
			// add another quad from latest 4 points of fan set to QS
			// order is ccw, i.e. in correct halfplane direction
			// note: there is an implicit "malloc" here for the'length' element of the array
			coordIndexNew [coordIndexNew.length] = index[ii];
			coordIndexNew [coordIndexNew.length] = index[ii+1];
			coordIndexNew [coordIndexNew.length] = index[ii+2];
			coordIndexNew [coordIndexNew.length] = index[ii+3];
			coordIndexNew [coordIndexNew.length] = -1;
		}

	  // incremental trace of array being built
	  tracePrint ('coordIndexNew=' + coordIndexNew);
	}
	renderedQS.set_coordIndex = coordIndexNew;
	tracePrint ('renderedQS.coordIndex=' + renderedQS.coordIndex);
	// match colorIndex if any Color node exists
//	if (nodesHolder.color)
//	{
//	  if (nodesHolder.color.color.length > 0)
//	  {
		//  Could implement color count check here
//	  }
//	}

	// no need to set colorIndex since indexedFaceSet semantics handles this
}
function set_index (value, timestamp)
{
	index = value;
	initialize ();
}
function tracePrint(outputString)
{
    if (localTraceEnabled)
	  Browser.println ('[IndexedQuadSet]' + outputString);
}
function alwaysPrint(outputString)
{
	Browser.println ('[IndexedQuadSet]' + outputString);
}

          
]]>
</Script>
<Group>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
</Group>
</Group>
</ProtoBody>
</ProtoDeclare>
<!-- ======================================== -->
<ProtoDeclare name='CADAssemblyappinfo='The CADAssembly node holds a set of assemblies or parts grouped together.' >
<ProtoInterface>
<field name='addChildrentype='MFNodeaccessType='inputOnly'/>
<field name='removeChildrentype='MFNodeaccessType='inputOnly'/>
<field name='childrentype='MFNodeaccessType='inputOutput'
 appinfo='The children field can contain X3DProductStructureChildNode types. Each child will be either a sub-assembly or a part.' >
<!-- Specification initialization: NULL node -->
</field>
<field name='nametype='SFStringaccessType='inputOutput'
 appinfo='The name field documents the name of this CADAssembly.' />

<field name='bboxCentertype='SFVec3fvalue='0 0 0accessType='initializeOnly'
 appinfo='Bounding box center: position offset from origin of local coordinate system.' />

<field name='bboxSizetype='SFVec3fvalue='-1 -1 -1accessType='initializeOnly'
 appinfo='Bounding box size: automatically calculated can be specified as an optimization or constraint.' />

<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<Group>
<IS>
<connect nodeField='addChildrenprotoField='addChildren'/>
<connect nodeField='removeChildrenprotoField='removeChildren'/>
<connect nodeField='childrenprotoField='children'/>
<connect nodeField='bboxCenterprotoField='bboxCenter'/>
<connect nodeField='bboxSizeprotoField='bboxSize'/>
</IS>
</Group>
<Group>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
<!-- name holder -->
<Anchor
  url=' "#hideWarning1" ' >
<IS>
<connect nodeField='descriptionprotoField='name'/>
</IS>
</Anchor>
</Group>
</ProtoBody>
</ProtoDeclare>
<!-- ======================================== -->
<ProtoDeclare name='ShapeHolderappinfo='local dummy node to hold value for CADFace' >
<ProtoInterface>
<field name='shapetype='SFNodeaccessType='inputOutput'>
<!-- no initialization value -->
</field>
</ProtoInterface>
<ProtoBody>
<Script DEF='HoldShapeNodeScriptdirectOutput='true'>
<field name='shapetype='SFNodeaccessType='inputOutput'
 appinfo='holder for IS field' >
<!-- no initialization node -->
</field>
<IS>
<connect nodeField='shapeprotoField='shape'/>
</IS>
<![CDATA[
          
ecmascript:
// no script code, this node is simply a container

// silence warning: no function provided that includes shape = something;

        
]]>
</Script>
</ProtoBody>
</ProtoDeclare>
<!-- = = = = = -->
<ProtoDeclare name='CADFaceappinfo='The CADFace node holds the geometry representing a face of a part.'  documentation=' https://www.web3d.org/x3d/specifications/ISO-IEC-19775-Amendment1-PDAM-X3DAbstractSpecification/Part01/components/CadGeometry.html#CADPart ' >
<ProtoInterface>
<field name='nametype='SFStringaccessType='inputOutput'
 appinfo='The name field documents the name of this CADFace.' />

<field name='shapetype='SFNodeaccessType='inputOutput'
 appinfo='[X3DShapeNode | LOD]' >
<!-- Specification initialization: NULL node -->
</field>
<field name='bboxCentertype='SFVec3fvalue='0 0 0accessType='initializeOnly'
 appinfo='Bounding box center: position offset from origin of local coordinate system.' />

<field name='bboxSizetype='SFVec3fvalue='-1 -1 -1accessType='initializeOnly'
 appinfo='Bounding box size: automatically calculated can be specified as an optimization or constraint.' />

<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<ProtoInstance name='ShapeHolder'>
<IS>
<connect nodeField='shapeprotoField='shape'/>
</IS>
</ProtoInstance>
<Group>
<IS>
<connect nodeField='bboxCenterprotoField='bboxCenter'/>
<connect nodeField='bboxSizeprotoField='bboxSize'/>
</IS>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
<!-- name holder -->
<Anchor
  url=' "#hideWarning2" ' >
<IS>
<connect nodeField='descriptionprotoField='name'/>
</IS>
</Anchor>
</Group>
</ProtoBody>
</ProtoDeclare>
<!-- ======================================== -->
<ProtoDeclare name='CADLayerappinfo='The CADLayer node defines a hierarchy of nodes used for showing layer structure.'  documentation=' https://www.web3d.org/x3d/specifications/ISO-IEC-19775-Amendment1-PDAM-X3DAbstractSpecification/Part01/components/CadGeometry.html#CADPart ' >
<ProtoInterface>
<field name='addChildrentype='MFNodeaccessType='inputOnly'/>
<field name='removeChildrentype='MFNodeaccessType='inputOnly'/>
<field name='childrentype='MFNodeaccessType='inputOutput'
 appinfo='The children field can contain X3DChildNode types.' >
<!-- Specification initialization: NULL node -->
</field>
<field name='nametype='SFStringaccessType='inputOutput'
 appinfo='The name field documents the name of this CADLayer.' />

<field name='visibletype='MFBoolaccessType='inputOutput'
 appinfo='specifies whether a particular child and its subchildren are visible. If the number of values is less than the number of children the remaining children shall be visible.' />

<field name='bboxCentertype='SFVec3fvalue='0 0 0accessType='initializeOnly'
 appinfo='Bounding box center: position offset from origin of local coordinate system.' />

<field name='bboxSizetype='SFVec3fvalue='-1 -1 -1accessType='initializeOnly'
 appinfo='Bounding box size: automatically calculated can be specified as an optimization or constraint.' />

<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<Group>
<IS>
<connect nodeField='addChildrenprotoField='addChildren'/>
<connect nodeField='removeChildrenprotoField='removeChildren'/>
<connect nodeField='childrenprotoField='children'/>
<connect nodeField='bboxCenterprotoField='bboxCenter'/>
<connect nodeField='bboxSizeprotoField='bboxSize'/>
</IS>
</Group>
<Group>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
<!-- name holder -->
<Anchor
  url=' "#hideWarning3" ' >
<IS>
<connect nodeField='descriptionprotoField='name'/>
</IS>
</Anchor>
</Group>
<Script DEF='HoldMFBoolFieldScript'>
<field name='visibletype='MFBoolaccessType='inputOutput'>
<!-- no initialization node -->
</field>
<IS>
<connect nodeField='visibleprotoField='visible'/>
</IS>
<![CDATA[
          
ecmascript:
// no script code, this node is simply a container

        
]]>
</Script>
<!-- No support for MFBool in VRML97, so no functionality provided for visible -->
</ProtoBody>
</ProtoDeclare>
<!-- ======================================== -->
<ProtoDeclare name='CADPartappinfo='CADPart represents the location and faces that constitute apart'  documentation=' https://www.web3d.org/x3d/specifications/ISO-IEC-19775-Amendment1-PDAM-X3DAbstractSpecification/Part01/components/CadGeometry.html#CADPart ' >
<ProtoInterface>
<field name='addChildrentype='MFNodeaccessType='inputOnly'/>
<field name='removeChildrentype='MFNodeaccessType='inputOnly'/>
<field name='childrentype='MFNodeaccessType='inputOutput'
 appinfo='The children field can only contain CADFace nodes.' >
<!-- Specification initialization: NULL node -->
</field>
<field name='nametype='SFStringaccessType='inputOutput'/>
<field name='translationtype='SFVec3fvalue='0 0 0accessType='inputOutput'/>
<field name='rotationtype='SFRotationvalue='0 0 1 0accessType='inputOutput'/>
<field name='centertype='SFVec3fvalue='0 0 0accessType='inputOutput'/>
<field name='scaletype='SFVec3fvalue='1 1 1accessType='inputOutput'/>
<field name='scaleOrientationtype='SFRotationvalue='0 0 1 0accessType='inputOutput'/>
<field name='bboxCentertype='SFVec3fvalue='0 0 0accessType='initializeOnly'/>
<field name='bboxSizetype='SFVec3fvalue='-1 -1 -1accessType='initializeOnly'/>
<field name='metadatatype='SFNodeaccessType='inputOutput'
 appinfo='[X3DMetadataObject]' >
<!-- Specification initialization: NULL node -->
</field>
</ProtoInterface>
<ProtoBody>
<Transform>
<IS>
<connect nodeField='childrenprotoField='children'/>
<connect nodeField='addChildrenprotoField='addChildren'/>
<connect nodeField='removeChildrenprotoField='removeChildren'/>
<connect nodeField='translationprotoField='translation'/>
<connect nodeField='rotationprotoField='rotation'/>
<connect nodeField='centerprotoField='center'/>
<connect nodeField='scaleprotoField='scale'/>
<connect nodeField='scaleOrientationprotoField='scaleOrientation'/>
<connect nodeField='bboxCenterprotoField='bboxCenter'/>
<connect nodeField='bboxSizeprotoField='bboxSize'/>
</IS>
</Transform>
<Group>
<MetadataString name='metadataHolder'>
<IS>
<connect nodeField='metadataprotoField='metadata'/>
</IS>
</MetadataString>
<!-- name holder -->
<Anchor
  url=' "#hideWarning4" ' >
<IS>
<connect nodeField='descriptionprotoField='name'/>
</IS>
</Anchor>
</Group>
</ProtoBody>
</ProtoDeclare>
<!-- ======================================== -->
<Anchor description='CadGeometryExternPrototypesparameter='"target=_blank"'
  url=' CadGeometryExternPrototypes.x3d"https://www.web3d.org/x3d/content/examples/Basic/development/CadGeometryExternPrototypes.x3d" "CadGeometryExternPrototypes.wrl" "https://www.web3d.org/x3d/content/examples/Basic/development/CadGeometryExternPrototypes.wrl" ' >
<Shape>
<Text string='"CadGeometryExternPrototypes" "defines prototype examples" "" "Click text to see" "CadGeometryExternPrototypes"'>
<FontStyle justify='"MIDDLE" "MIDDLE"size='0.9'/>
</Text>
<Appearance>
<Material diffuseColor='1 1 0.2'/>
</Appearance>
</Shape>
</Anchor>
<!-- ======================================== -->
<Transform translation='-3 2 0'>
<Shape>
<Appearance DEF='White'>
<Material diffuseColor='1 1 1'/>
</Appearance>
<ProtoInstance name='IndexedQuadSetcontainerField='geometry'>
<fieldValue name='indexvalue='0 3 2 1 4 5 6 7 2 7 9 8 2 3 4 7'/>
<fieldValue name='coord'>
<Coordinate point='-1.5 0 0 -1.5 1 -1 -.5 1 -1 -.5 0 0 0.5 0 0 1.5 0 0 1.5 1 -1 0.5 1 -1 -0.5 2 -1 0.5 2 -1'/>
</fieldValue>
</ProtoInstance>
</Shape>
</Transform>
<Transform translation='3 2 0'>
<Shape>
<Appearance USE=' White'/>
<ProtoInstance name='QuadSetcontainerField='geometry'>
<fieldValue name='coord'>
<Coordinate point='-1.5 0 0 -1.5 1 -1 -0.5 1 -1 -0.5 0 0 0.5 0 0 1.5 0 0 1.5 1 -1 0.5 1 -1'/>
</fieldValue>
</ProtoInstance>
</Shape>
</Transform>
<!-- ======================================== -->
<!-- Silence scene warnings by providing ordered ProtoInstance examples. Note warning above that this scene is for developmental use. The ProtoInstance form of the CAD nodes should not be used, native X3D encoding should be used instead. -->
<ProtoInstance name='CADLayer'>
<fieldValue name='children'>
<ProtoInstance name='CADAssembly'>
<fieldValue name='children'>
<ProtoInstance name='CADPart'>
<fieldValue name='children'>
<ProtoInstance name='CADFace'>
<fieldValue name='shape'>
<Shape>
<Cylinder bottom='falseheight='0.000001radius='0.000001side='false'/>
<Appearance>
<Material/>
</Appearance>
</Shape>
</fieldValue>
</ProtoInstance>
</fieldValue>
</ProtoInstance>
</fieldValue>
</ProtoInstance>
</fieldValue>
</ProtoInstance>
</Scene>
</X3D>
<!--

to top <!-- Event Graph ROUTE Table shows event connections -->
 
<!-- Index for DEF nodes: HoldMFBoolFieldScript, HoldShapeNodeScript, IndexedQuadSetToIndexedFaceSet, QuadSetToIndexedFaceSet, RenderedIQS, RenderedQS, UnrenderedIQS, UnrenderedQS, White

Index for ProtoDeclare definitions: CADAssembly, CADFace, CADLayer, CADPart, IndexedQuadSet, QuadSet, ShapeHolder
-->

Event Graph ROUTE Table with 0 ROUTE total, showing X3D event-model relationships for this scene.

Each row shows an event cascade that may occur during a single timestamp interval between frame renderings, as part of the X3D execution model.

IndexedQuadSetToIndexedFaceSet
Script
No ROUTE connection found for output from this node.
Contains SFNode field with indirect access to another node. 


QuadSetToIndexedFaceSet
Script
No ROUTE connection found for output from this node.
Contains SFNode field with indirect access to another node. 



ProtoInstance
ShapeHolder
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
IndexedQuadSet
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
QuadSet
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
CADLayer
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
CADAssembly
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
CADPart
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 



ProtoInstance
CADFace
No ROUTE connection found for output from this node.
Contains SFNode/MFNode field with indirect access to other nodes. 


-->

<!-- Online at
https://www.web3d.org/x3d/content/examples/Basic/CAD/CadGeometryPrototypesIndex.html -->
<!-- Version control at
https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examples/Basic/CAD/CadGeometryPrototypes.x3d -->

<!-- Color legend: X3D terminology <X3dNode DEF='idName' field='value'/> matches XML terminology <XmlElement DEF='idName' attribute='value'/>
(Light-blue background: event-based behavior node or statement) (Grey background inside box: inserted documentation) (Magenta background: X3D Extensibility)
    <ProtoInstance name='ProtoName'> <field name='fieldName'/> </ProtoInstance> -->

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