[vtkusers] VTK + Java adding actors

Peter F Bradshaw pfb at users.sourceforge.net
Thu Feb 15 01:52:17 EST 2001


On Tue, 13 Feb 2001, Brian Henz wrote:

> I have VTK and Java working on SGI and Linux but an having some trouble with 
> the following.  I create a vtkPanel and then add actors to it which are 
> displayed and I can interact with them.  But I can only interact with the 
> actors added in the same function where new vtkPanel was called.  If I 
> create the Panel and pack it, and then add actors when a button is pushed 
> they are not viewable or interactive but they do exist because I can do 
> getRenderer().GetActors() and then list the actors.
> 
> When I try to interact with the actors I get
> Exception occurred during event dispatching:
> java.lang.NullPointerException
>   at vtk.vtkPanel.mouseDragged(vtkPanel.java:211, Compiled Code)
>   at java.awt.Component.processMouseMotionEvent(Component.java:3204, 
> Compiled Code)
>   at java.awt.Component.processEvent(Component.java:3003, Compiled Code)
>   at java.awt.Component.dispatchEventImpl(Component.java:2394, Compiled 
> Code)
>   at java.awt.Component.dispatchEvent(Component.java:2307, Compiled Code)
>   at java.awt.EventQueue.dispatchEvent(EventQueue.java:287, Compiled Code)
>   at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:101, 
> Compiled Code)
>   at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:92, 
> Compiled Code)
>   at java.awt.EventDispatchThread.run(EventDispatchThread.java:83, Compiled 
> Code)
> 
> 
> Any ideas would be helpful.

Hi;

You don't say which JDE you are using. I fixed a lot of problems similar to
that above by changing from IBM's JDE r1.3 to Sun's JRE r1.3. If you are using
IBMS kit this may be your problem.

Cheers

--
Peter F Bradshaw          | http://members.dingoblue.net.au/~pfb
pfb at users.sourceforge.net | PGP public key at
http://www.pfb.tsx.org    | http://members.dingoblue.net.au/~pfb/public_key.html
ICQ 75431157 (exadios)    | "Needs more salt" - Archimedes






More information about the vtkusers mailing list