Is there another Sphere object already in the scene graph?  By default
our geometry primitive utilities cache and share Geometry objects.  So,
if one already exists in the scene graph, the Geometry could already
be live.  A quick check is to check the value of Geometry.isLive().
To turn off this sharing, create the Sphere with the
Primitive.GEOMETRY_NOT_SHARED flag.

As for the SimpleUniverse case, many parts of the scene graph are made
live when a SimpleUniverse is created - specifically the view side of
the scene graph.


Doug Twilleager
Java 3D Team
Sun Microsystems

>Delivered-To: [EMAIL PROTECTED]
>MIME-Version: 1.0
>Content-Transfer-Encoding: 7bit
>X-Priority: 3 (Normal)
>X-MSMail-Priority: Normal
>Importance: Normal
>X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4
>Subject: Re: [JAVA3D] RestricedAccess Exception
>To: [EMAIL PROTECTED]
>
>I got a very similar message with de SimpleUniverse class.
>When I asked for his LocalToVWorld transform, I got the could not change
>capabilities in a live
>or compiled scene message.
>
>I think that auxiliar classes like Sphere, SimpleUniverse,etc are
>pre-compiled,
>or these functions aren't available for the user.
>
>> -----Mensaje original-----
>> De: Discussion list for Java 3D API
>> [mailto:[EMAIL PROTECTED]]En nombre de Jonathan Albert C.
>> Vallar
>> Enviado el: jueves 7 de junio de 2001 18:17
>> Para: [EMAIL PROTECTED]
>> Asunto: [JAVA3D] RestricedAccess Exception
>>
>>
>> Hi! I have a Sphere object.Below are my declarations:
>>
>>
>>
>>          a.setMaterial(m);
>>
>>             //spheres
>>             //new sphere
>>
>>             sph = new Sphere(0.2f, Sphere.GENERATE_NORMALS, 80, a);
>>             sph.setPickable(true);
>>
>>
>>
>>             Shape3D shp3d = sph.getShape();
>>
>>             shp3d.setCapability(Shape3D.ALLOW_GEOMETRY_READ);
>>
>>             Geometry geo = shp3d.getGeometry();
>>             -----------> geo.setCapability(Geometry.ALLOW_INTERSECT);
>>
>> This is declared before the sphere is added to the scenegraph. It
>> compiles but when I instantiate thisa object by a DND operation,
>> I get a restrictedaccess exception, not being able to modify
>> capability bits. The error points to the line with an arrow. Why?
>>
>> Thanks!
>>
>> __________________________________
>> www.edsamail.com
>>
>> ==================================================================
>> =========
>> 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".
>>
>
>===========================================================================
>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".

===========================================================================
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".

Reply via email to