[x3d-public] Nodes for V4; X3D Script and HTML script coexist; prototypes without embedded Script nodes

Don Brutzman brutzman at nps.edu
Wed Aug 31 08:09:29 PDT 2016


On 8/28/2016 9:32 PM, Leonard Daly wrote:
> catching up....
>
>> Thanks for your continuing efforts.  Feedback:
>>
>> a. Not clear what your motivation is.  What functionality does a Macro node provide that isn't already available using Script and Prototype definitions?  Getting clear about differences helps getting clear about goals.
>
> X3D Script is not available in HTML as it is already being used.

The X3D Script node is not the same as the HTML script element.  So there is no collision, only the need for precision when discussing it.  Both coexist nicely already, as they have for two decades.

The Scene Authoring Interface (SAI) efforts for X3D (probably v3.0) was able to successfully reconcile differences in JavaScript and Java that were necessary under the VRML97 External Authoring Interface (EAI).  In that way, the same class structures and programming patterns were usable in author source code - an author could write the same kind of X3D-related source code in JavaScript or Java, with event updates and field updates still working consistently.

Among multiple reasons, it is also good to note that HTML5 explicitly supports the <object> tag for plugins, so we can expect that the consistency of SAI is likely to still work across various forms of invocation.  As ever, exploration and testing is advisable.

> After repeated requests to X3D and X3D-Public mailing lists, no one could supply an example of a trivial PROTO (one without a Script node) that was not convenience definition.

I repeatedly provided the Universal Media Materials examples in response to your request, both on the email list and I also believe it came up during a teleconference.

These are found in the X3D Basic Examples archives.

	http://www.web3d.org/x3d/content/examples/Basic/UniversalMediaMaterials

Sample declaration:

<ProtoDeclare name='ArtDeco00' appinfo='UniversalMediaMaterials prototype' documentation=' http://www.web3d.org/x3d/content/examples/Basic/UniversalMediaMaterials '>
	<ProtoBody>
		<Material ambientIntensity='0.25' diffuseColor='0.282435 0.085159 0.134462' shininess='0.127273' specularColor='0.276305 0.11431 0.139857'/>
	</ProtoBody>
</ProtoDeclare>

Also as suggested earlier, further scenes of interest appear in the X3D example archives.  Here is a quick search for you.

Three such prototypes also appear as examples supporting _X3D for Web Authors_ and are online at

	http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes

Another interesting scene that does not include a Script node can be found in the same directory:

	http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HeadsUpDisplayPrototype.x3d
	http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HeadsUpDisplayPrototype.html

	http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HeadsUpDisplayExample.x3d
	http://x3dgraphics.com/examples/X3dForWebAuthors/Chapter14-Prototypes/HeadsUpDisplayExample.html

Looks like 5 more examples (5deepinternalroute.x3d 5deepnesting.x3d def.x3d route_inside.x3d and simple.x3d) can be found in

	X3D Example Archives: Conformance Nist, Miscellaneous, PROTO.
	http://www.web3d.org/x3d/content/examples/ConformanceNist/Miscellaneous/PROTO

Eight more scenes appear in

	X3D Example Archives: VRML 2.0 Sourcebook, Chapter 31 - Prototypes
	http://www.web3d.org/x3d/content/examples/Vrml2.0Sourcebook/Chapter31-Prototypes/

Of those, most do no include Script.  Perhaps of special interest is the SpinGroup prototype, which was originally proposed as a VRML node.  Demonstrating this node as a prototype in VRML showed that specification addition was not necessary.  The term commonly used in those days was "avoiding node bloat" to keep the VRML vocabulary as concise as possible, i.e. avoiding the addition of duplicative nodes.

> I felt that the ability to define a set of nodes at initialization (parse-type) was useful. I added the ability to vary the parameters from one instance to the next as important to provide variability in the scene.

ProtoDeclare field declarations, and ProtoInstance fieldValue instances, can contain either simple types (MFVec3f etc.) or SF/MFNode initializations.

Thus prototypes have full expressivity to extend any node functionality in X3D.

ProtoInstance fieldValue insertions would be the right place to vary parameters from one instance to the next.

Similarly Inline IMPORT/EXPORT can pass initialization values that are either simple types or node types, as singletons or as arrays.

Hence the questions regarding how Macro compares and contrasts.  Differences hold the greatest interest.

Also that is why Macro itself may itself be implementable as an X3D Prototype, with an embedded Script to parse the expressions provided at run time.  Or not, depending on your design goals.  Again, both possibilities are interesting.

> The Macro node definition (linked in the OP) is part of a much larger document that includes the section "Author's Notes" (http://tools.realism.com/specification/x3d-v40/authors-notes) where the motivation and domain of operation are described. There is also a link to the "Author's Notes" section in the sidebar.

OK... and what is the goal motivation for Macro, and comparison to prototype/inline functionality, please?

>> b. Usage examples are often helpful for illustrating goals at this stage of design.
>
> Each node comes with at least one test case. Andreas has collected the test scenes and provide me information as to how that can be made part of the Github pages. I will be working on that.

Thanks, looking forward to that.  Nothing proprietary, please.

>> c. Previous efforts on NetworkSensor node, and the difficulties encountered, may be worth considering:
>>
>>     http://www.web3d.org/x3d/content/examples/Basic/Networking/
>>     http://www.web3d.org/x3d/content/examples/Basic/Networking/NetworkSensorConnectionPrototypes.x3d
>>     http://www.web3d.org/x3d/content/examples/Basic/Networking/NetworkSensorConnectionPrototypes.html
>>
>>     http://www.web3d.org/x3d/content/examples/Basic/Networking/NetworkSensorConnectionNodes.html
>
> Communication between users (networking) is a useful area to investigate. I was involved in the previous attempt and remember many of the difficulties and different approaches that the WG had. In the end we were unable to define anything for the specification because the problem scope was not sufficiently well-defined and agreed-upon. Things in the HTML world have changed considerably since then and it would probably be useful to try to get that kind of communication going again. I do not know if it is appropriate to put that in X3D or better to handle external of X3D in (e.g.) WebRTC.
>
> I do not understand why it was brought up here. It is not a topic I brought up.

Apologies for not expressing that relationship more clearly.  The topic pertains because NetworkSensor is similar to Prototype in that a player needs to create custom scene-graph fields, just as Prototype declarations do.  Thus the design of NetworkSensor (which has different goals that Macro) and its dynamic parameters seems quite reasonable.  Unfortunately no successful implementations occurred because all of the prototype implementations were inside player codebases and the owners/principals didn't want to pursue it.  Even so, given the greater number of options now, someone might want to implement it.

Hopefully the lessons learned from dynamic creation of X3D content by NetworkSensor can also inform your design.

>> d. Then noticed that you have applied a (CC BY-ND) No Derivatives license, which specifically forbids any adaptation.
>>
>>     https://creativecommons.org/licenses/by-nd/3.0/us/
>>
>>     https://en.wikipedia.org/wiki/Creative_Commons_license
>>     "No Derivative Works (ND)"
>>     "Licensees may copy, distribute, display and perform only verbatim copies of the work, not derivative works and remixes based on it."
>>
>> Unfortunately that discourages further consideration.
>
> At this time I am not submitting this for consideration for V4. I did not want multiple versions of the document existing. That would make it hard to determine the differences between the different documents. I am aware of the requirements for consideration and the document will comply with those requirements when it is submitted. The CC BY-ND license does not discourage consideration as changes can be sent to me for incorporation. If there are several people interested in working on the document, I will supply other mechanisms for editing/updating.

You are of course welcome to do what you like, Leonard.  No pressure from me.  Meanwhile you posted this information as "Nodes for V4" which presumably invited consideration.  The X3D Working Group is happy to do so, but of course is also obliged to follow Consortium rules.  Hence the conflict between your license and our ability to properly consider.

For everyone's information, any technology submissions for X3D version 4 or any other Web3D Consortium technology are welcome.  In order to be properly considered, any contributions are obliged to follow the Web3D Intellectual Property Rights (IPR) rules.  In essence, technology is either confirmed to be royalty free from the start, or guaranteed to be royalty free if accepted.

 From the web3D.org STANDARDS tab

	Standards Adoption Process
	http://www.web3d.org/standards/adoption-process

	Standards Submission Policy
	http://www.web3d.org/standards/submission-policy
  
> Leonard Daly

Thanks for your continuing efforts, hope that all of this information is considered helpful.


>> On 8/26/2016 7:39 PM, Leonard Daly wrote:
>>> For the last year I have been working on advancing X3D to be standardized in HTML5/DOM environment and support mobile and VR. I have just completed alpha work on the Macro node. This node provides the static definition capabilities of PROTO in an HTML5 environment. It can perform string substitution (name/value pairs) on X3D code stored externally. The node documentation is at http://tools.realism.com/specification/x3d-v40/abstract-specification/changes-additions-x3d-v33/macro.
>>>
>>> I will continue to get to at least alpha stage (basic functional implemented and working) for all nodes I discussed during my presentations at Web3D2016 & SIGGRAPH. The presentation is online at http://realism.com/presentations/188?title=Extending-X3DOM-to-Mobile.
>>>
>>> All of the code is up on Github at https://github.com/DrX3D/x3dv4 with testing code.
>>>
>>> I am interested in any bugs that are found or new/revised direction for the nodes. I am completely open to anyone who would like to help code.

all the best, Don
-- 
Don Brutzman  Naval Postgraduate School, Code USW/Br       brutzman at nps.edu
Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149
X3D graphics, virtual worlds, navy robotics http://faculty.nps.edu/brutzman



More information about the x3d-public mailing list