Apple has proposed adding a <model> element to HTML to display 3D content in the browser using a built-in renderer.

183 views
Skip to first unread message

Theo Armour

unread,
Sep 1, 2021, 2:27:44 PM9/1/21
to webgl-d...@googlegroups.com
Do you have any thoughts on this? Good idea or not?


From the README:

tl;dr

We propose adding a <model> element to HTML that displays 3D content using a renderer built-in to the browser.

Introduction
HTML allows the display of many media types through elements such as <img>, <picture>, or <video>, but it does not provide a native manner to directly consume 3D content. Embedding such content within a page is comparatively cumbersome and relies on scripting the <canvas> element. We believe it is time to put 3D models on equal footing with other, already supported, media types.

There is a variety of prior art here: For example, three.js and Babylon JS are WebGL frameworks that can process many different formats. Then there is the model-viewer project which shows models inline in a web page, and also allows users on some devices to see the 3D object in augmented reality. And iOS Safari has the ability to navigate directly to an augmented reality view with its [AR Quick Look feature] (https://webkit.org/blog/8421/viewing-augmented-reality-assets-in-safari-for-ios/).

However, there are cases where these current options cannot render content. This might be due to security restrictions or to the limitations of <canvas> (see below for more details on motivation).

The HTML <model> element aims to allow a website to embed interactive 3D models as conveniently as any other visual media. Models are expected to be created by 3D authoring tools or generated dynamically, but served as a standalone resource by the server.

Additionally, besides the simple display of a 3D model, the <model> element should have support for interactivity and animations while presented within the page, and also support more immersive experiences, such as augmented reality.

This proposal does not aim to define a mechanism that allows the creation of a 3D scene within a browser using declarative primitives or a programmatic API.

Ken Russell

unread,
Sep 3, 2021, 1:09:55 AM9/3/21
to WebGL Dev List
Hi Theo,

There's been quite a lot of discussion about it on Twitter. Our teammate Brandon Jones shared his thoughts, quite eloquently in my opinion.

There are some AR use cases - multiple websites publishing models into the same shared space - which may be best served by introducing a <model> tag. It may be difficult to allow multiple sites all to cooperatively use WebXR and either WebGL or WebGPU to render those objects into the same scene.

The thing is - we haven't tried yet. Maybe it's not as difficult as it seems.

I think that for these use cases we should try to use the specifications that we've spent so long developing, including WebGL, WebGPU, WebXR and glTF 2.0. These allow amazingly powerful and customizable experiences to be developed on the web. Starting from a declarative model tag may seem compelling at first, but in order for it to be useful - anything more than a toy - more and more functionality will need to be added, up to *and including* the ability to dynamically generate geometry down to the vertex. Our community has spent literally a decade getting the APIs and JavaScript engines to the point where they can do this.

Apple's proposal first ignored the existence of the glTF file format. Now that that's been corrected, it still ignores the existence of the WebXR specification. To me, this seems a bit single-minded.

-Ken



--
You received this message because you are subscribed to the Google Groups "WebGL Dev List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to webgl-dev-lis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/webgl-dev-list/CACyLXqGtyhMyDgRmEcE%3Dq%2B1cA3dDTaGxPd9BV1gYeAc1JodC3Q%40mail.gmail.com.

Theo Armour

unread,
Sep 3, 2021, 2:53:42 AM9/3/21
to webgl-d...@googlegroups.com
Ken

Thank you for the Twitter link.

There is a most interesting dialog going on.

It's interesting that nobody from Apple seems to be participating. It makes me think:

If you live in a walled garden it may be difficult to see further even when you stand on the shoulders of giants.

I will read the Apple proposal in more detail before commenting myself.

Off the top of my head: Doing something "so it just works" is cool. BTW: "Don't make me change." 

;-)

Theo

Theo Armour

unread,
Sep 3, 2021, 2:56:01 AM9/3/21
to webgl-d...@googlegroups.com
Oops, I now see that some Apple peeps are in the dialog
Reply all
Reply to author
Forward
0 new messages