Thanks
cambounds = v.getGCamera().getViewBounds()
which asks the camera what it's looking at, and then this selects the
nodes in that region:
(x >= cambounds.x) & (x <= (cambounds.x + cambounds.width)) & (y >=
cambounds.y) & (y <= (cambounds.y + cambounds.height))
you might need to play a little with the widths and heights of nodes,
but it mostly works.
-Eytan
> --
> You received this message because you are subscribed to the Google Groups "guess-discuss" group.
> To post to this group, send email to guess-...@googlegroups.com.
> To unsubscribe from this group, send email to guess-discus...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/guess-discuss?hl=en.
>
>
On 10 mrt, 14:46, Eytan Adar <eytana...@gmail.com> wrote:
> It's a pretty gross violation of abstraction barriers, but if you're
> using the piccolo interface (this is default), you can do:
>
> cambounds = v.getGCamera().getViewBounds()
>
> which asks the camera what it's looking at, and then this selects the
> nodes in that region:
>
> (x >= cambounds.x) & (x <= (cambounds.x + cambounds.width)) & (y >=
> cambounds.y) & (y <= (cambounds.y + cambounds.height))
>
> you might need to play a little with the widths and heights of nodes,
> but it mostly works.
>
> -Eytan
>
found out that Guess.getFrame() equally returns a GFrame. than it is
only a mather of making a minar adjustment to the Guess source.
In GFrame.java add:
public MySelectionHandler getSelectionHandler(){
return pseh;
}
when using Guess.getFrame() just cast it to GFrame. and than you will
have everything you need.