[x3d-public] visual shape differencing with x3d

John Carlson yottzumm at gmail.com
Sun Jul 2 21:50:15 PDT 2023


This sounds really cool.  I hope to use my earth cutout example, with a
solid earth instead of using "fake" techniques.

Thanks,

John

On Sun, Jul 2, 2023 at 11:21 AM Andreas Plesch <andreasplesch at gmail.com>
wrote:

> Let me share that we found that it is possible to simulate
> differencing of shapes in x3dom to a useful degree. This allows for
> transparent cutouts or holes:
>
>
> https://andreasplesch.github.io/Library/Viewer/index.html?url=https://gist.githubusercontent.com/andreasplesch/415d151abee114858c79c20c8c4b49e0/raw/4c70463321df267b28298462af76b869adbfdfdb/BoxWithHoles183.x3d
>
> The idea is to draw first transparent shapes which define the holes,
> including to the depth buffer. Then standard drawing of the solid
> shape will be hidden where the holes 'obscure' it (although the holes
> are actually transparent).
>
> To do that requires two changes to default rendering of transparent
> shapes. For best rendering normally transparent shapes are rendered
> last and do not write to the depth buffer. Here they are drawn first
> and do write to the depth buffer.
>
> In x3dom this is implemented by allowing explicit definition of the
> sort (rendering) order of shapes (with a sortKey field), and by
> allowing direct access to the gl depthmask function with a Depthmode
> node.
>
> An easy way to generate cutouts or holes which is otherwise only
> possible with external CSG tools is a powerful use case for these
> lower-level x3d extensions. Perhaps other browsers have similar
> features or are inspired to consider those.
>
> Andreas
>
> --
> Andreas Plesch
> Waltham, MA 02453
>
> _______________________________________________
> x3d-public mailing list
> x3d-public at web3d.org
> http://web3d.org/mailman/listinfo/x3d-public_web3d.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230702/3fb71974/attachment.html>


More information about the x3d-public mailing list