[x3d-public] [x3dom-users] X3DOM ProtoDeclares that work.
John Carlson
yottzumm at gmail.com
Sat May 2 09:08:41 PDT 2020
It doesn't make much sense to go to JSON and back to a DOM document when
you already have a document or XML, unless the problem cannot be solved by
XML. I think that XML may be unsatisfactory unless we create the DOM
document disconnected from the page DOM (?), which is likely what I did
with JSON. This is what I call a "shadow DOM," building a document behind
the scenes. I don't know what a correct "shadow DOM" is and I probably
shouldn't use the term.
Thanks for the clarification, it helps.
We don't want to build the DOM document interactively with a live DOM.
John
On Sat, May 2, 2020 at 7:46 AM Andreas Plesch <andreasplesch at gmail.com>
wrote:
> John had already provided his JSONExpander to x3dom a while back, so
> Protos ( without scripts ) work for a while in x3dom. The limitation
> is currently that they are only working with the json encoding, eg. in
> json encoded inlines. So we would need an XMLExpander as well, perhaps
> by going through json. I looked into shadow dom a while ago. The main
> problem was that x3dom.js cannot look into the shadow dom. The shadow
> dom is by design cut off from being accessed.
>
> It think I made the HUD work by removing a sensor or another smaller
> change.
>
> Note that HAnim works on X3DOM, no protos need. But the Nancy
> prototypes are a good test for expanding.
>
> The typical approach for webgl skinned animation is do it on the
> shader. I tried that somewhat but it would require larger
> architectural changes, for delivering the data to the shader. I think
> it would need to be done by float textures. There is a branch on the
> x3dom github repo.
>
> Not sure if there is a general approach to big data in the browser.
> Overall, for real big data (TB) the browser can only be a thin client,
> receiving a stream. It is unclear what role X3D can play there.
>
> -Andreas
>
> On Fri, May 1, 2020 at 10:21 PM John Carlson <yottzumm at gmail.com> wrote:
> >
> > Don, for more "wow," you might try NancyPrototypes.json. The XML
> freezes that tab of the browser. I didn't wait. JSON is quite quick.
> However, input does not work in all cases, because the HUD is
> unavailable. I am pretty happy with the results on NancyPrototypes.json!
> Better than a dismembered humanoid! I suggest we purse the next version
> in XML, possible with shadow DOM.
> >
> > Perhaps we should get together with Andreas, Joe, You, and Me, and we
> should discuss how to deal with "big data" in a web browser. I think
> perhaps we might go with WebASM for HAnim. We can look at how various
> languages compile to WebASM, and do some comparison between X3D browsers
> compiled to WebASM. I would appreciate Andreas' architecture and software
> design input on the development of a 2nd generation Prototype Expander for
> X3DOM. If your contacts are working with WebASM, we can bring them into
> the conversation.
> >
> > On Fri, May 1, 2020 at 7:19 PM Don Brutzman <brutzman at nps.edu> wrote:
> >>
> >> John: thanks 1M for showing "X3DOM ProtoDeclares that work", very
> important capability! Wow. 8)
> >>
> >> Recommend that you and X3DOM community continue and integrate this work
> to restore the "X" in X3DOM: extensibility. Prototypes are a central
> aspect of X3D, as is scripting. Getting these squared away in X3DOM will
> be a major step towards achieving two complete open-source independent
> implementations of X3D4 running inside HTML5.
> >>
> >> v/r Don
> >>
> >>
> >> On 5/1/2020 12:42 PM, John Carlson wrote:
> >> > https://coderextreme.net/X3DJSONLD/src/main/html/proto.html
> >> >
> >> > select one of the X3D files that start with ./data/
> >> >
> >> > Like:
> >> >
> >> > ./data/bubs.x3d
> >> > ./data/rubik.x3d
> >> > ./data/x3domflowers.x3d
> >> > ./data/X3dHeaderPrototypeSyntaxExamples.x3d
> >> >
> >> > If you run my app.js server (requires SSL keys) locally, then you can
> test more of the x3d resources examples by checking out the X3D
> sourceforge project to /c/x3d-code/www.web3d.org/. <http://www.web3d.org/
> .>..
> >> >
> >> > Start the server with
> >> >
> >> > node app.js
> >> >
> >> > then go to https://localhost:3000/src/main/html/proto.html
> >> >
> >> > then select some of the ./www.web3d.org/. <http://www.web3d.org/.>..
> files.
> >> >
> >> > Note that this does proto expansion on JSON, so first i translate
> from XML to JSON, then do the proto expansion, then convert back to XML.
> >> >
> >> > You may optionally turn off scripting and proto expansion, if you
> want to see differences.
> >> >
> >> > There need to be some effort to make this work in all cases.
> >> >
> >> > 1. Don't hog graphics contexts.
> >> > 2. Fix up Scripting on X3DOM. This may be possible with Scripts.js
> (not recommended). Primarily, I recommend fixing routing to/from scripts
> in X3DOM. That may mean approaching the w3c to allow fields in a script
> nodes.
> >> > 3. Make sure PROTOs are working in all cases. Please file issues
> against X3DJSONLD. I already know there are many unwritten issues.
> https://github.com/coderextreme/X3DJSONLD/issues
> >> >
> >> > Note that app.js does not work on a production machine purposefully.
> You may want to rewrite app.js in python. Whatever floats your boat,
> changes are welcome.
> >> >
> >> > John
> >> > _______________________________________________
> >> > X3dom-users mailing list
> >> > X3dom-users at lists.sourceforge.net
> >> > https://lists.sourceforge.net/lists/listinfo/x3dom-users
> >>
> >> 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
> >
> > _______________________________________________
> > X3dom-users mailing list
> > X3dom-users at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/x3dom-users
>
>
>
> --
> Andreas Plesch
> Waltham, MA 02453
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20200502/0d892994/attachment.html>
More information about the x3d-public
mailing list