Currently we create a <canvas> element and place it at the <xml3d> element's DOM position. This implicit mutation of the DOM is not very elegant and might confuse an application.
With Shadow DOM functionality we can hide the canvas inside the <xml3d> element's shadow tree. Hence we would not have to modify the (exposed) DOM.
Unfortinately, only a small subset of browsers support Shadow DOM. One could use the Shadow DOM where available and, at the same time, provide a unified access to the <canvas> element (e.g. as a property of the <xml3d> element).
Currently we create a
<canvas>
element and place it at the<xml3d>
element's DOM position. This implicit mutation of the DOM is not very elegant and might confuse an application.With Shadow DOM functionality we can hide the canvas inside the
<xml3d>
element's shadow tree. Hence we would not have to modify the (exposed) DOM.Unfortinately, only a small subset of browsers support Shadow DOM. One could use the Shadow DOM where available and, at the same time, provide a unified access to the
<canvas>
element (e.g. as a property of the<xml3d>
element).