[x3d-public] removeNamedNode removes DEF children?
Patrick Dähne
pdaehne at gmail.com
Mon Jul 11 11:08:35 PDT 2022
> Am 11.07.2022 um 19:27 schrieb Andreas Plesch <andreasplesch at gmail.com>:
>
> On Mon, Jul 11, 2022, 12:34 PM Patrick Dähne <pdaehne at gmail.com> wrote:
> > Thanks, very helpful. After the DEF name is removed, do the USE nodes still rrefer to the now nameless node ?
>
> Yes. The scene graph does not care about DEF and USE, it is only needed to serialize the scene graph into a textual representation.
>
> Ok.
>
>
>
> > Also, is there then a way to remove a node from the scene graph ?
>
> Yes, send events to fields (usually Group.children or Group.removeChildren).
>
> Presumably, outer.removeChildren(inner) would then just remove the child (DEF) node. The USE node would still refer to the (original) DEF node ?
Yes.
> Is there a way to remove all instances of a named node at once ?
No.
Bye,
Patrick
More information about the x3d-public
mailing list