[x3d-public] lights in switch nodes

Leonard Daly Leonard.Daly at realism.com
Fri May 11 13:01:13 PDT 2018


Andreas,

The spec text that only the selected child of a Switch is traversed. It 
doesn't explicitly state it, but I presume that means is rendered (or at 
least considered for rendering). All children of a Switch participate in 
event handling (sending and receiving, including state changes).

At one time (~20 years ago), lighting was expensive and limited to 8 
lights. Light scoping was limited so the scene could be rendered. I have 
not really seen scoped lights in quite a while. I think it is possible, 
but you need to go to extra work to make it happen. Unfortunately, X3D 
(spec) has not kept pace with the rest of the graphics community on 
lighting, while many of the applications have.

I would not consider it good practice to include lights as an indirect 
child because they can have an impact beyond the limit of the node.


Leonard Daly



Children of switch nodes still participate in all events; however the
> Since lights are child nodes, they can occur as children of switch nodes.
>
> Presumably that means that only light nodes which are traversed in the
> switch are active and should be used for illumination. Others occuring
> in the switch should be turned off. Is that the intended behaviour ?
>
> I am asking because switch is mostly used with Shape nodes, and x3dom
> currently uses all lights whereever they occur.
>
> Thanks, Andreas
>

-- 
*Leonard Daly*
3D Systems & Cloud Consultant
LA ACM SIGGRAPH Past Chair
President, Daly Realism - /Creating the Future/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20180511/29276272/attachment.html>


More information about the x3d-public mailing list