<div><div dir="auto">Well, the first video was the first time I had focused on triggers and sequencers.</div><div dir="auto"><br></div><div dir="auto">Can I have a float-random-sequencer?   Is that an emitter?</div><div dir="auto"><br></div><div dir="auto">John</div></div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Aug 15, 2020 at 11:38 AM Don Brutzman <<a href="mailto:brutzman@nps.edu">brutzman@nps.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)">Thanks for your continuing efforts.  Tricky business, but... we only have to get it right once and then it works for everyone.  Plus multiple open-source implementations exist.<br><br><br><br>On 8/14/2020 6:12 PM, John Carlson wrote:<br><br>> <br><br>> Is there an IS (International Standard), as opposed to a CD (Committee Draft?)?<br><br><br><br>On the Web3D Consortium's Recommended Standards page, a legend table appears at the bottom that explains the acronyms:<br><br><br><br>[1] Recommended Standards<br><br>     <a href="https://www.web3d.org/standards" rel="noreferrer" target="_blank">https://www.web3d.org/standards</a><br><br><br><br>CD      Committee Draft<br><br>        First vote with technical comments on proposed standard or revision.<br><br>DIS     (was FCD) Draft International Standard (was Final Committee Draft)<br><br>        Last vote with technical comments on proposed standard or revision.<br><br>FDIS    Final Draft International Standard<br><br>        Last ISO vote on proposed standard or revision. This is a Yes/No vote only.<br><br>IS      International Standard<br><br>        Approved and published standard or revision.<br><br><br><br>Then listed above, row by row, are entries for each recommended standard.  Of interest here:<br><br><br><br>19777-1 ISO/IEC CD 19777-1:201x<br><br>        V3.3<br><br>        X3D Language Bindings : ECMAScript (JavaScript)<br><br>        CD 2014-09-05<br><br>        HTML <a href="https://www.web3d.org/documents/specifications/19777-1/V3.3/index.html" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19777-1/V3.3/index.html</a><br><br>        ZIP  <a href="https://www.web3d.org/documents/specifications/19777-1/V3.3/ISO-IEC-19777-1-CD-V3.3.zip" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19777-1/V3.3/ISO-IEC-19777-1-CD-V3.3.zip</a><br><br><br><br>> I was guessing once I got field support working, that events would be automatic? Not really sure...  I guess I'll have to do the set_, _changed stuff, but I'm not really sure.  Maybe I should do initializing in the initialize() method?<br><br><br><br>Guessing is not possible, unless you have language-algorithm ESP maybe...  Reading the specification is how to be sure.<br><br><br><br>In scripts, the initialize() method is automatically called first, and the shutdown() method is automatically called last.<br><br><br><br>Three ! specifications describe functionality: X3D Architecture, X3D Scene Access Interface, and the Ecmascript language binding.<br><br><br><br>Recommend reading them, key sections follow.<br><br><br><br>[2.1] X3D Abstract : Node Definitions, with formal title<br><br>       X3D Part 1: Architecture and base components<br><br><br><br>        4.4.2.2 Field semantics<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#FieldSemantics" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#FieldSemantics</a><br><br><br><br>        4.4.2.4 Modifying objects<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#Modifyingobjects" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#Modifyingobjects</a><br><br><br><br>        4.4.8 Event model<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#Eventmodel" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#Eventmodel</a><br><br><br><br>        29.2 Scripting component, concepts<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/scripting.html#Concepts" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/scripting.html#Concepts</a><br><br><br><br>[2.2] 19775-2 X3D Abstract : Scene Access Interface (SAI), with formal title<br><br>       19775-2 X3D Part 2: Scene access interface (SAI)<br><br>       <a href="https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/X3D_SAI.html" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/X3D_SAI.html</a><br><br><br><br>        4.4.8 Node and node lifecycle<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/concepts.html#Node" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/concepts.html#Node</a><br><br><br><br>        4.4.9 Field<br><br>        <a href="https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/concepts.html#Field" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19775-2/V3.3/Part02/concepts.html#Field</a><br><br><br><br>[2.3] X3D language bindings, Part 1: ECMAScript<br><br>       <a href="https://www.web3d.org/documents/specifications/19777-1/V3.3/index.html" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19777-1/V3.3/index.html</a><br><br><br><br>        5.2.11 Script content services<br><br>        <a href="https://www.web3d.org/documents/specifications/19777-1/V3.3/Part1/tables.html#ScriptServices" rel="noreferrer" target="_blank">https://www.web3d.org/documents/specifications/19777-1/V3.3/Part1/tables.html#ScriptServices</a><br><br><br><br>Whew, that is a lot.  All together now, presented in different ways (examples, book, slides, videos):<br><br><br><br>[3.1] X3D Example Archives: X3D for Web Authors, Chapter 09 Event Utilities Scripting<br><br>       <a href="https://x3dgraphics.com/examples/X3dForWebAuthors/Chapter09EventUtilitiesScripting" rel="noreferrer" target="_blank">https://x3dgraphics.com/examples/X3dForWebAuthors/Chapter09EventUtilitiesScripting</a><br><br><br><br>[3.2] X3D For Web Authors, Chapter 9, Event Utilities and Scripting<br><br>       <a href="http://x3dgraphics.com" rel="noreferrer" target="_blank">http://x3dgraphics.com</a><br><br><br><br>[3.3] Chapter 9, Event Utilities and Scripting, slideset<br><br>       <a href="http://x3dgraphics.com/slidesets/X3dForWebAuthors/Chapter09EventUtilitiesScripting.pdf" rel="noreferrer" target="_blank">http://x3dgraphics.com/slidesets/X3dForWebAuthors/Chapter09EventUtilitiesScripting.pdf</a><br><br><br><br>[3.4] YouTube course videos: Chapter 9, Event Utilities and Scripting<br><br>       <a href="https://www.youtube.com/playlist?list=PLuSIsM-86sik26mcDz0w_wdFXOUp56FTr" rel="noreferrer" target="_blank">https://www.youtube.com/playlist?list=PLuSIsM-86sik26mcDz0w_wdFXOUp56FTr</a><br><br><br><br>And as you've seen, simplest summaries (including Hints and Warnings) are found at<br><br><br><br>[4.0] X3D Tooltips: Script<br><br>       <a href="https://www.web3d.org/x3d/content/X3dTooltips.html#Script" rel="noreferrer" target="_blank">https://www.web3d.org/x3d/content/X3dTooltips.html#Script</a><br><br><br><br>> I haven't figured out how to call shutdown() yet. document.onunload?<br><br>> <br><br>> It would seem like if I copied field stuff from Composed Shader/Shader Part, that I would get the default fields?  I am not really sure.<br><br>> Should I look at Andreas' ProtoDeclare? Are there other places with fields?<br><br><br><br>Prototypes can contain Script nodes so however this is implemented needs to be compatible.  The design of fields and events are identical, with prototypes holding more involved capabilities for extensibility.<br><br><br><br>... so yes, you need to align well with Andreas' ProtoDeclare.  The only other nodes with fields are the Shader nodes, and they are slight variations on Script.<br><br><br><br>> Thanks,<br><br>> <br><br>> John<br><br><br><br>Likewise, further questions welcome.  These are worthy efforts!  Good luck with your important efforts.<br><br><br><br>all the best, Don<br><br>-- <br><br>Don Brutzman  Naval Postgraduate School, Code USW/Br       <a href="mailto:brutzman@nps.edu" target="_blank">brutzman@nps.edu</a><br><br>Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149<br><br>X3D graphics, virtual worlds, navy robotics <a href="http://faculty.nps.edu/brutzman" rel="noreferrer" target="_blank">http://faculty.nps.edu/brutzman</a><br><br></blockquote></div></div>