<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style></head><body lang=EN-US link=blue vlink="#954F72"><div class=WordSection1><p class=MsoNormal>Thanks for fixing this so quickly!  You must be busy!  Also, we need a  file:www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter14-Prototypes/HudPrototype.json in the X3dExampleArchivesJsonScenes.zip zip file (and .x3d in the file system possibly).   This has been requested before, but no explanation given for it’s non-inclusion (did I miss something?)</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Mentioned here (I rewrite URLs to use .json) for the ExternProtoDeclare stuff:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><span style='color:#70AD47'>examples/X3dForWebAuthors/Chapter14-Prototypes/HudKelpForest.json:              </span>"@url":["HudPrototype.x3d#HUD","http://X3dGraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HudPrototype.x3d#HUD","HudPrototype.wrl#HUD","http://X3dGraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HudPrototype.wrl#HUD"],<span style='color:#70AD47'><o:p></o:p></span></p><p class=MsoNormal><span style='color:#70AD47'>examples/X3dForWebAuthors/Chapter14-Prototypes/HudKelpForest.x3d:    </span><ExternProtoDeclare name='HUD' url='"HudPrototype.x3d#HUD" "http://X3dGraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HudPrototype.x3d#HUD" "HudPrototype.wrl#HUD" "http://X3dGraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HudPrototype.wrl#HUD"'></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Does this scene need more work?  Or does it need to be deleted?  Just wondering!</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>John</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Sent from <a href="https://go.microsoft.com/fwlink/?LinkId=550986">Mail</a> for Windows 10</p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p> </o:p></span></p><div style='mso-element:para-border-div;border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal style='border:none;padding:0in'><b>From: </b><a href="mailto:yottzumm@gmail.com">John Carlson</a><br><b>Sent: </b>Saturday, July 2, 2016 6:21 AM<br><b>To: </b><a href="mailto:brutzman@nps.edu">Don Brutzman</a><br><b>Cc: </b><a href="mailto:x3d-public@web3d.org">X3D Graphics public mailing list</a><br><b>Subject: </b>RE: Transform node which has a DEF used as MFNode?</p></div><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p> </o:p></span></p><p class=MsoNormal>Isn’t it inconsistent to provide both value=’HudContent’ and children below in (b)?  What does the JSON conversion come up with?</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks,</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>John</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Sent from <a href="https://go.microsoft.com/fwlink/?LinkId=550986">Mail</a> for Windows 10</p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p> </o:p></span></p><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b>From: </b><a href="mailto:brutzman@nps.edu">Don Brutzman</a><br><b>Sent: </b>Friday, July 1, 2016 8:04 PM<br><b>To: </b><a href="mailto:yottzumm@gmail.com">John Carlson</a><br><b>Cc: </b><a href="mailto:x3d-public@web3d.org">X3D Graphics public mailing list</a><br><b>Subject: </b>Re: Transform node which has a DEF used as MFNode?<o:p></o:p></p></div><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p> </o:p></span></p><p class=MsoNormal>On 7/1/2016 10:55 AM, John Carlson wrote:<o:p></o:p></p><p class=MsoNormal>> http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HudKelpForest.x3d has a ProtoDeclare field of hudGeometry which has type MFNode.  The ProtoInstance field value points to a DEF which is a Transform.  Is the transform an MFNode or an SFNode?    I will assume that if a fieldValue has a value that is of MFNode type, then there is a DEF somewhere that refers to the value?   Or does the MFNode type mean gather all DEFs and USEs and use them together as a parameter?</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Whoa, great catch John.  Pretty trick example.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The current source looks like</p><p class=MsoNormal>(a)</p><p class=MsoNormal>     <ProtoInstance DEF='Hud' name='HUD'></p><p class=MsoNormal>       <fieldValue name='hudSize' value='1.5 .4 .1'/></p><p class=MsoNormal>       <fieldValue name='hudColor' value='1 1 0'/></p><p class=MsoNormal>       <fieldValue name='screenOffset' value='-.8 1. -3'/></p><p class=MsoNormal>       <fieldValue name='hudGeometry' value='HudContent'/></p><p class=MsoNormal>     </ProtoInstance></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I think that is probably incorrect.  Expected form is</p><p class=MsoNormal>(b)</p><p class=MsoNormal>     <ProtoInstance DEF='Hud' name='HUD'></p><p class=MsoNormal>       <fieldValue name='hudSize' value='1.5 .4 .1'/></p><p class=MsoNormal>       <fieldValue name='hudColor' value='1 1 0'/></p><p class=MsoNormal>       <fieldValue name='screenOffset' value='-.8 1. -3'/></p><p class=MsoNormal>       <fieldValue name='hudGeometry' value='HudContent'/></p><p class=MsoNormal>                <Transform USE='HudContent'/></p><p class=MsoNormal>       </fieldValue></p><p class=MsoNormal>     </ProtoInstance></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Unfortunately the X3D Schematron validation doesn't flag this as a problem.  It probably should.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>>  I am not familiar with using DEF values as values for ProtoInstances, but I will try to implement the Prototype Expander that way.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I don't think we ever defined that functionality.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Looking at X3D Extensible Markup Language (XML) encoding, Clause 4 Concepts</p><p class=MsoNormal>http://www.web3d.org/documents/specifications/19776-1/V3.3/Part01/concepts.html</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>and then</p><p class=MsoNormal>4.3.10 ProtoInstance and fieldValue statement syntax</p><p class=MsoNormal>http://www.web3d.org/documents/specifications/19776-1/V3.3/Part01/concepts.html#ProtoInstanceAndFieldValueStatement</p><p class=MsoNormal>=============================</p><p class=MsoNormal>The ProtoInstance element is used to create instances of nodes, which must be defined previously in the scene using either ProtoDeclare or ExternProtoDeclare statements.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>ProtoInstance can contain zero or more fieldValue elements which are used to provide initial values for fields defined in the corresponding predecessor ProtoDeclare or ExternProtoDeclare statement. These fieldValue initializations are only used for field definitions with accesstype of initializeOnly or inputOutput and override any default values defined in the corresponding ProtoDeclare.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>EXAMPLE</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>     <Transform translation='0 -2.5 0'></p><p class=MsoNormal>       <Shape></p><p class=MsoNormal>         <Appearance></p><p class=MsoNormal>           <ProtoInstance name='EmissiveMaterial'></p><p class=MsoNormal>             <fieldValue name='onlyColor'</p><p class=MsoNormal>                         value='0.2 0.6 0.6'/></p><p class=MsoNormal>           </ProtoInstance></p><p class=MsoNormal>         </Appearance></p><p class=MsoNormal>         <Text string='"Prototype syntax" "examples"'></p><p class=MsoNormal>           <FontStyle justify='"MIDDLE" "MIDDLE"'/></p><p class=MsoNormal>         </Text></p><p class=MsoNormal>       </Shape></p><p class=MsoNormal>     </Transform></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>     <ProtoInstance name='ViewPositionOrientation'></p><p class=MsoNormal>       <fieldValue name='enabled' value='true'/></p><p class=MsoNormal>     </ProtoInstance></p><p class=MsoNormal>=============================</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>So there is no example given of a ProtoInstance fieldValue providing an SFNode/MFNode value.  We should provide one.  Form (b) above is legal by the rest of the X3D XML Encoding specification.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Since there is no definition of the shorthand for form (a) above, it isn't legal.  I will create an X3D Schematron rule to detect and report it.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Since this shorthand in form (a) is pretty interesting, but can only represent a single SFNode USE name, and might be considered ambiguous, not sure we ought to allow it in a future version of the specification.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Might anyone like to make a case for (or against) form (a) as an allowed alternative approach in the X3D XML Encoding?</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>all the best, Don</p><p class=MsoNormal>-- </p><p class=MsoNormal>Don Brutzman  Naval Postgraduate School, Code USW/Br       brutzman@nps.edu</p><p class=MsoNormal>Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149</p><p class=MsoNormal>X3D graphics, virtual worlds, navy robotics http://faculty.nps.edu/brutzman</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>