Hi,
Hvae you enabled pick reporting on all the nodes between the picked leaf and the root?
Only those nodes that have pick reporting enabled will show up in the scene graph path
(I think.. a while since I looked at
picking).
Cheers,
Brad
"Gerald (Ted) Quon" wrote:
>
> Hi,
>
> I am trying to use the PickTool object to allow the user of a 3D
> environment to choose any part of a loaded scene graph (using a
> pointer-like device), and subsequently translate/rotate the entire scene
> graph using this pointer device.
>
> However, although the user is able to pick an object (a Shape3D object),
> when I try to use the getSceneGraphPath() function of PickResult, the
> resulting SceneGraphPath object that is returned contains only the
> terminal leaf (the Shape3D object) and the root object - all nodes
> inbetween (which I have manually verified do exist) are not part of the
> returned pathway.
>
> The following is a snippet of code used to retrieve the picked object and
> resultant scene graph path:
>
> -------------------------------------------------------
>
> //create a PickTool for the current Locale and make it a cylinder
> PickTool pickTool = new PickTool(getLocale());
> pickTool.setShapeCylinderRay(wandOrigin, wandDirection, 10.0);
>
> PickResult result = pickTool.pickClosest();
>
> //make sure the user picks a valid object
> if (result != null)
> {
> SceneGraphPath path = result.getSceneGraphPath();
> System.out.println("Number of nodes in path: " + path.nodeCount());
> // ...
> }
>
> ---------------------------------------------
>
> This problem persists no matter what kind of scene graphs I load into
> Java3D.
>
> Any suggestions on why the SceneGraphPath returned has no intermediate
> nodes? Thanks!
>
> Ted
>
> ===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff JAVA3D-INTEREST". For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
----------------------------------------------------------------------------
This Email may contain confidential and/or privileged information and is
intended solely for the addressee(s) named. If you have received this
information in error, or are advised that you have been posted this Email by
accident, please notify the sender by return Email, do not redistribute it,
delete the Email and keep no copies.
----------------------------------------------------------------------------
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".