[x3d-public] TAG finding on Polyfills and the evolution of the Web: request for comment

Michalis Kamburelis michalis.kambi at gmail.com
Tue Nov 7 20:16:46 PST 2017


2017-11-08 3:03 GMT+01:00 Don Brutzman <brutzman at nps.edu>:
> Polyfills and the evolution of the Web
>

I'm not sure is this useful, but I thought about what is the
equivalent of "polyfills" in the scope of X3D:

In the scope of X3D, an equivalent to a "polyfill" is defining an
EXTERNPROTO that defines a node that is part of the X3D specification
(or expected to become part of the X3D specification soon), but not
yet implemented by all X3D browsers. This way even X3D browsers that
don't (yet) implement this node can continue to operate as expected.

To make it work nicely (like a good "polyfill"), one specifies 2 (or
more) URNs indicating the EXERNPROTO implementation. The first URN
should indicate specification-compliant implementation (so that the
EXTERNPROTO will use the native implementation, if possible). The last
URN should refer to a PROTO implementation that provides (at least to
some degree) a compatible implementation of this node using other
nodes.

See
- X3D spec about EXTERNPROTO:
http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/concepts.html#Externalprototypesemantics
- Web3d RFC about URN: http://www.ietf.org/rfc/rfc3541.txt?number=3541

For example, if the Teapot node would become part of the X3D standard,
one could use this polyfill:

- https://github.com/castle-engine/demo-models/blob/master/prototypes/teapot_externproto.x3dv
- https://github.com/castle-engine/demo-models/blob/master/prototypes/teapot_fallback_implementation.x3dv

(Tested in view3dscene).

Regards,
Michalis



More information about the x3d-public mailing list