Duplicating a Node

John Hendrikx hjohn at xs4all.nl
Fri Mar 15 11:07:09 PDT 2013


Hi list,

I'm trying to achieve an effect that requires me to make a copy of a 
Node, apply some effect(s) on it (PerspectiveTransform, Clip, Blend and 
perhaps DisplacementMap) and place it in the same scenegraph together 
with the original.

It is very similar to what Reflection achieves, but without alternating 
the size of the Node, and without the limitations (specifically, 
creating the correct Reflection for an object that has a 
PerspectiveTransform applied to it already cannot be done with Reflection).

I would prefer not to have to make an actual copy of the Node, as they 
might get out of sync and not display the same content when they should 
be.  Something like a NodeReference class, that takes another Node as 
parameter but applies different effects/clips/transforms.

Since the code I'm using for this is based on Cells getting laid out, 
I'm toying with the idea of actually asking the provider of those cells 
twice for the same cell and applying different transformations on each, 
but they might get out of sync and it seems there should be a better way.

Any ideas or suggestions at how I could best achieve this, or would it 
be a new feature?

--John


More information about the openjfx-dev mailing list