light and Bound

Hi All,

Sorry for my English

I add 2 AmbientLight objects to my Scene and set the regions of influence as 2 distinct BoundingSphere (one for each light) objects but with the same parameters, e.g. Point3d(0,0,0) and radius 10;

I add one light to the BranchGroup and one light to TransformGroup that translate the object by (0,-2,0)

When I print the lights’ influencing bounds via getInfluencingBounds() method
I get the same answer for both lights! :

Center=(0.0, 0.0, 0.0) Radius=10.0

but according to the pdf of Sun on Java 3D
the bounds are local to the light system of coordinate and should translate too, so why I don’t get
for the second light Center=(0.0, -2.0, 0.0) Radius=10.0. Somthing I don’t understand.please help me

Thank u in advance
Eyal

I haven’t used J3D in months, but I think that the method result is correct, since it returns the geometry associated with the light (in the ligth’s cooordinate system).

In the rendering phase the geometry is translated with the light by the transform group, but the sphere continues to be centered at the light’s origin.

To know the new origin, you should try to ask for the Transform3D object of the transform group, and transform the point(0,0,0) with it.