<html xmlns:v="urn:schemas-microsoft-com:vml" 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=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@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:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"Plain Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
span.PlainTextChar
        {mso-style-name:"Plain Text Char";
        mso-style-priority:99;
        mso-style-link:"Plain Text";
        font-family:"Calibri","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-GB link=blue vlink=purple><div class=WordSection1><p class=MsoPlainText>That's an Interesting set of points you raise.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>I agree that the LoadSensor probably can't be used  because the <i>watchList</i> field requires nodes derived from URL object. And EXTERNPROTO, although it has a URL, isn't a node.<o:p></o:p></p><p class=MsoPlainText>On the other hand, the creation and setting up of the instance takes place when the file is being read in. This will include things like IS and ROUTE, etc. So as the loading takes place during the file loading phase there is no need for the LoadSensor. Indeed, it wouldn’t be able to send any messages until the setup  phase was completed.  Thus, referring to Kristian’s comment, the loading phase for the file would proceed through the EXTERNPROTO declaration until it came to the prototype instance. This would then load immediately and be set up before reading the file proceeded to the next node. Consequently ROUTEs could be used immediately after the instance in the file. Obviously and dynamic routing (e.g. via Scripts) would not start until the whole scene graph loading was completed and became live. So there isn’t an issue there.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>Inline, on the other hand, does not have to read the URL during the setup phase. The stated purpose of the <i>load</i> field is effectively one of input, not output (although it is inputOutput type). So setting <i>load</i> to FALSE prevents the Inline from loading until it is needed, as opposed to loading immediately if <i>load</i> is TRUE. The specification makes no mention of any output activity. So it would be necessary to use a LoadSensor if it was desired to monitor an Inline.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>I too have noted that you have to specify the list of fields For external prototypes in two places. However, avoiding that can’t be easily avoided. The use of a subset of the fields does allow an author to only declare those fields of the EXTERNALPROTOTYPE that need to be in the top level file. However, there is no reason why all the fields should not be included, albeit that the specification says “shall be a subset”. I think the specification ought to say “shall be all or a subset”. Another suggestion for V3.4 I think.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>Roy<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText><span lang=EN-US style='mso-fareast-language:EN-GB'>-----Original Message-----<br>From: x3d-public [mailto:x3d-public-bounces@web3d.org] On Behalf Of doug sanden<br>Sent: 12 March 2015 14:15<br>To: X3D Graphics public mailing list<br>Subject: Re: [x3d-public] External prototypes</span></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>I suspect Networking component> LoadSensor <a href="http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/networking.html#LoadSensor"><span style='color:windowtext;text-decoration:none'>http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/networking.html#LoadSensor</span></a><o:p></o:p></p><p class=MsoPlainText>cannot be used, because the URL is on the EP declaration, not the instance, and the declaration isn't in the scenegraph where LoadSensor can get to it. And there are extra steps after the declaration is loaded, to populate the instances and hook up the IS routes to the instance interface.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>Networking Component> Inline has a .load field [in,out] and I suspect it sends an event out TRUE when it's loaded.<o:p></o:p></p><p class=MsoPlainText><a href="http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/networking.html#Anchor"><span style='color:windowtext;text-decoration:none'>http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/networking.html#Anchor</span></a><o:p></o:p></p><p class=MsoPlainText>Ideally EPIs would have that too.<o:p></o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>><o:p> </o:p></p><p class=MsoPlainText>> Ideally I think there should be a .loaded event or testable field on the externProtoInstance (the interface), so you can test / know when it's ready for routing.<o:p></o:p></p><p class=MsoPlainText>> -Doug<o:p></o:p></p><p class=MsoPlainText>><o:p> </o:p></p><p class=MsoPlainText>>> when declaring external prototypes, the author needs to declare the <o:p></o:p></p><p class=MsoPlainText>>> subset of the interface she intends to use by replicating those <o:p></o:p></p><p class=MsoPlainText>>> fields from the prototype declaration (cf X3D spec 4.4.5.2)<o:p></o:p></p><p class=MsoPlainText>>><o:p> </o:p></p><p class=MsoPlainText>>> What is the rationale behind this? Seem to make the implementation a <o:p></o:p></p><p class=MsoPlainText>>> little bit simpler, but since events that occure before the prototype <o:p></o:p></p><p class=MsoPlainText>>> has been resolved are ignored anyway, this is really just a little bit.<o:p></o:p></p><p class=MsoPlainText>>> However it complicates the use of external prototypes because it's a <o:p></o:p></p><p class=MsoPlainText>>> popular source of error (at least for my first steps with prototypes <o:p></o:p></p><p class=MsoPlainText>>> at times when maybe the error messages in then popular X3D browsers <o:p></o:p></p><p class=MsoPlainText>>> where improvable).<o:p></o:p></p><p class=MsoPlainText>>><o:p> </o:p></p><p class=MsoPlainText>>> But maybe I miss something.<o:p></o:p></p><p class=MsoPlainText>>><o:p> </o:p></p><p class=MsoPlainText>>> Best,<o:p></o:p></p><p class=MsoPlainText>>> Kristian<o:p></o:p></p><p class=MsoPlainText>><o:p> </o:p></p><p class=MsoPlainText><o:p> </o:p></p><p class=MsoPlainText>                                                                                  <o:p></o:p></p><p class=MsoPlainText>_______________________________________________<o:p></o:p></p><p class=MsoPlainText>x3d-public mailing list<o:p></o:p></p><p class=MsoPlainText><a href="mailto:x3d-public@web3d.org"><span style='color:windowtext;text-decoration:none'>x3d-public@web3d.org</span></a><o:p></o:p></p><p class=MsoPlainText><a href="http://web3d.org/mailman/listinfo/x3d-public_web3d.org"><span style='color:windowtext;text-decoration:none'>http://web3d.org/mailman/listinfo/x3d-public_web3d.org</span></a><o:p></o:p></p></div></body></html>