[x3d-public] X3D minutes 11 DEC 2020: X3D4 Annex L, HTML authoring guidelines
Don Brutzman
brutzman at nps.edu
Sat Dec 12 19:34:22 PST 2020
Meeting followup summary: changes applied to draft specification. Ready for review.
* X3D Architecture, Annex L, HTML authoring guidelines
https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-WD3/Part01/htmlGuidelines.html
Dick and I will take one last look and promote all "editorsNote" styles to "proposed" for balloting.
On 12/11/2020 4:15 PM, Don Brutzman wrote:
> [...]
> We will work on finalizing topics list and concept details for
>
> [1] X3D4 Architecture, Annex L HTML authoring guidelines (informative)
> https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-WD3/Part01/htmlGuidelines.html
>
> "Editors note: this draft Annex gives general guidelines for how X3D scenes can be displayed and interactive as part of HTML5/DOM Web-page presentations. Current focus by X3D practitioners is open-source implementation and evaluation using X3DOM and X_ITE. Further improvements are expected."
>
> Am redrawing Figure L.1 with an illustration too.
Prose follows, figure attached for email archive, original visio diagram also checked into Web3D Consortium X3D specification github.
================================================
L.4.2 HTML and X3D synchronization
An example approach to HTML X3D Event-Passing Connections is shown in Figure L.1, Example HTML X3D Rendering Synchronization and Event-Passing Connections. This diagram illustrates potential timing and synchronization for rendering of an HTML page and an X3D model, with possibility of event passing between them. It is important to achieve repeatable behavior and efficient rendering with interactive response to user focus.
These relationships are conceptual and not necessarily indicative of any individual implementation, in a manner similar to Figure 4.1 — X3D architecture and Figure 4.3 — Conceptual execution model. Multiple design variations are permitted for HTML-X3D implementations as long as functional requirements of both HTML and X3D specifications are met.
* Figure L.1 — Example HTML X3D Rendering Synchronization and Event-Passing Connections
https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-WD3/Images/EventModelConnectionsHtmlX3d.png
Shared HTML events and X3D events (if available) are sent and received at end of each respective render cycle. Once initiated, an X3D event cascade proceeds to completion before any further external events are exchanged (see 4.4.8.3 Execution model).
Of note is that both HTML and X3D languages include definitions for a Script node, so disambiguation is necessary. One possible approach is to require that only X3D Script nodes can appear between X3D elements within an HTML page. An alternative approach is that any X3D Script node located within HTML page might be renamed X3DScript to avoid any name collisions.
================================================
> All reactions and inputs welcome.
>
> Discussion points:
>
> a. Limiting number of references to SVG. Hoping to keep it minimalist but note that W3C recommendations for HTML5 and CSS refer to it repeatedly. It also provides multiple design patterns for integration. Hoping to keep references limited and definitely _not_ any kind of requirement.
Simply noted as last entry among X3D design goals - we don't want reinvention of common/standard practice for HTML interaction with a graphics canvas.
================================================
L.2 X3D implementations in HTML browsers
The Hypertext Markup Language (HTML) is the World Wide Web’s core markup language. HTML is a general description language for documents and online applications [W3C-HTML5].
The Document Object Model (DOM) defines a string-based node tree that represents HTML or XML documents as a string-based node tree, also defining event-based processing methods that can be implemented by multiple programming languages. [W3C-DOM] [W3C-HTML5].
X3D provides a general-purpose architecture for publishing and sharing 3D graphics models. Since X3D utilizes Web standards and includes an XML file encoding, it is well suited for integration in HTML5 pages over the World Wide Web.
X3D design includes multiple goals related to use with HTML5/DOM:
* Compatibly present X3D models as a "first-class media type" similar to other audio and video formats.
* Harmonize event models so that user interaction within the HTML page can also affect the X3D model, and vice versa.
* Encourage standards compliance wherever possible while also enabling ongoing innovation and interoperability improvements.
* Allowing usage of multiple file encodings, for example a url address might point to XML, ClassicVRML, JSON, or another file encoding.
* Allowing one or more distinct X3D scenes to be be loaded at one time within an HTML page.
* Where possible, follow HTML5 page-integration patterns specified by Scalable Vector Graphics (SVG) [W3C-SVG].
These general guidelines for X3D model display and interaction as part of Web-page presentations allow continuing innovation and adaptability.
================================================
> b. References added for Annex L are informative and found in Bibliography, not required.
>
> c. Lots of past references for CSS relevant to X3D, especially outstanding papers by XML3D for Web3D Conferences.
refined and committed.
> d. How can we collect and share references of interest? (Specification annex stays pretty terse, even when informative - it is not a tutorial or survey.)
Future work on resources and best practices is needed. Non-final-spec notes and links remain present with strikeout as "proposedDeletion" for availability during ballot review.
> d. L.3.5 Cross-Origin Resource Sharing (CORS) considerations" belongs elsewhere? At a minimum put an editors note to that effect. Initiate work to document best practices for CORS and X3D, perhaps as Scene Authoring Hints section.
Streamlined but this section remains necessary I think. It will be very good to get continued discussion and feedback.
Note we had a dedicated working group meeting earlier this year on this topic that collects a useful set of information.
* X3D minutes 24 April 2020: Cross-origin resource sharing (CORS)
http://web3d.org/pipermail/x3d-public_web3d.org/2020-April/012364.html
> e. Discussed "Design goals for X3D and CSS include achieving a level of functionality similar to that which exists for HTML and CSS." Agreed that "class" and "style" are reserved, not say much more about that. Reserving the attributes does not require support in other languages but does allow persistence of that information to travel across encodings/bindings in a lossless manner.
improved prose, reserving both 'class' and 'style' fields for all X3D nodes, found additional W3C reference of direct relevance to style attribute as well.
================================================
L.3.3 Cascading Style Sheets (CSS) considerations
Cascading Style Sheets (CSS) is a language for describing the rendering of structured documents (such as HTML and XML) on screen, on paper, etc. CSS is a core language for the Web that is commonly used for separation of content and presentation, improving layout flexibility.
Design goals for X3D and CSS include achieving levels of functionality similar to that which exists for HTML and CSS.
CSS comprises multiple specifications listed in the latest version of CSS Snapshot Recommendation [W3C-CSS-Snapshot]. CSS can be applied and used for Web pages using HTML syntax or XHTML syntax [W3C-HTML5], Scalable Vector Graphics (SVG) [W3C-SVG], and Extensible Markup Language (XML) [W3C-XML] documents, such as models defined using the X3D XML encoding [I19776].
The reserved /class/ attribute on each X3D node can provide a space-separated list of classes that pertain from associated stylesheets.
The reserved /style/ attribute on each X3D node permits direct definition of style information, rather than referring to styles defined in a separate document [W3C-CSS-Style] [W3C-CSS-Snapshot].
================================================
* W3C-CSS-Snapshot
Cascading Style Sheets (CSS) Snapshot 2018, World Wide Web Consortium (W3C) Working Group Note, 22 January 2019.
https://www.w3.org/TR/css-2018/
* W3C-CSS-Style
Cascading Style Sheets (CSS) Style Attributes, World Wide Web Consortium (W3C) Recommendation, 7 November 2013.
https://www.w3.org/TR/css-style-attr
> h. L.4.3 JavaScript considerations
>
> "The Script node for X3D scene graph located within HTML page can be renamed X3DScript for disambiguation with HTML Script node."
>
> Might also say "Any Script node contained within a pair of X3D open/close tags is an X3D Script."
>
> Point out that X3D ECMAScript requirements can likely be met by using proper subset of JavaScript, following requirements of X3D EcmaScript language binding 19777-1.
how's this:
================================================
L.4.2 JavaScript considerations
Specified API capabilities for X3D Script node are defined in Scene Authoring Interface (SAI) [I19775-2] and X3D ECMAScript encoding [I19776].
Browser implementations and language versions for JavaScript/ECMAScript engines can vary. Since X3D SAI functional requirements are carefully scoped to match the core capabilities of this core Web programming languages, a single JavaScript/ECMAScript engine can typically be used for both HTML and X3D event handling.
Unified implementation for JavaScript/ECMAScript is often important for both performance and synchronization issues, especially when considering the demanding requirements of immersive interfaces and spatial body-tracking devices.
================================================
> g. Further interesting that L.4.4 User focus has to be sorted out. Our editing question is how minimalist is minimalist? Can we point out that issues exist? For example, if an X3D scene includes transparent Background and user selects/drags across transparent area (with no geometry) where does the event go: X3D player, HTML page or both?
how's this:
================================================
L.4.3 User focus considerations
User focus of attention refers to which part of an HTML page is receiving user-directed events for selection, dragging, etc. This often-simple capturing of events can nevertheless become quite sophisticated as both displays and device interfaces vary widely.
X3D provides a consistent selection and navigation interface across a wide range of devices that is based on platform-neutral model definitions. Suggested device mappings providing consistent user semantics are defined in Annex G Recommended navigation behaviours. Such flexibility is especially important when designing model display and interactions that support user accessibility.
Web browsers implementing HTML pay attention to user focus according to [W3C-HTML5] and direct user-driven events to DOM implementations of the document graph [W3C-DOM]. These are the governing references regarding disposition of events according to user focus prior to receipt by the X3D render engine.
Of interest is that X3D scenes can include Background transparency which may reveal underlying HTML content unobscured by geometry. X3D browsers may optionally pass through user-driven events back to underlying HTML layers.
================================================
> f. Interesting discussion confirming that X3D is in charge of X3D events, and HTML is in charge of HTML events. This can be basis of L.4.5 User Interaction.
I think we have sufficient words above. Deleted this section.
Also deleted "L.3.3 Attributes for the X3D element" since X3DOM and X_ITE are quite different:
||================================================
||====proposedDeletion, strikeout=================
||
|| L.3.3 X3D statement attributes
||
|| Attributes of X3D or X3DCanvas element: url/src, width, height, others... Do we need to decide on url, or src, or either, or no fixed requirement? Current approaches remain far apart.
||
|| X3DOM Configuration lists many candidate attributes of interest for x3d element.
|| https://doc.x3dom.org/author/configuration.html
||
|| X_ITE Attributes of the X3DCanvas Tag lists many candidate attributes of interest for x3d element.
|| https://github.com/create3000/x_ite/wiki#attributes-of-the-x3dcanvas-tag
||
|| Editorial assessment: not yet sufficiently stable for guidelines, further implementation and evaluation work is needed.
||
||====proposedDeletion, strikeout=================
||================================================
Comments from X3DOM and X_ITE implementers are especially welcome, all feedback is appreciated.
Here we go... Have fun with X3D4 and HTML5 and CSS! 8)
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
-------------- next part --------------
A non-text attachment was scrubbed...
Name: EventModelConnectionsHtmlX3d.png
Type: image/png
Size: 87591 bytes
Desc: not available
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20201212/1e83f2ab/attachment-0001.png>
More information about the x3d-public
mailing list