[vtkusers] Newbie Java question (yet another)
Jeff Lee
jeff at cdnorthamerica.com
Wed Dec 20 09:17:12 EST 2000
Greg,
I don't know much about windows systems, but it sounds like either you
don't have all of the vtk libraries in your library path, or vtkJava.dll
may not be linked properly with all of the other vtk libraries
(vtkGraphics.dll, vtkGraphicsJava.dll, vtkCommon.dll, etc... ). I don't
know how to check this on a windows box, though - on unix it would be
"ldd -r libvtkJava.so" and that would tell you what libraries are pulled
in by libvtkJava.so. As far as the jar stuff goes, I haven't tried to
use it. Instead I make my CLASSPATH point to $VTKHOME/java and to the
current directory.
-Jeff
"Johnson, G (Greg)" wrote:
>
> Hmm. I guessed that maybe vtkPanel should be in vtk.jar and wasn't so I
> stuffed it in and BINGO it compiles. However, I get a new error when trying
> to run the code:
>
> D:\Program\vtk31\java>java sphere
> Exception in thread "main" java.lang.UnsatisfiedLinkError: VTKInit
> at vtk.vtkObject.<init>(vtkObject.java:77)
> at sphere.<init>(sphere.java:28)
> at sphere.main(sphere.java:86)
>
> I am guessing that VTKInit is a startup routine in the vtkJava.dll - right?
> Any clues on how to fix this one?
>
> Cheers,
> greg
>
> Greg Johnson, Design Engineer
> CLRC Rutherford Appleton Laboratory, Chilton, UK
> g.johnson at rl.ac.uk -- www.clrc.ac.uk
>
> -----Original Message-----
> From: Johnson, G (Greg) [mailto:G.Johnson at rl.ac.uk]
> Sent: Wednesday, December 20, 2000 11:56 AM
> To: 'vtkusers at public.kitware.com'
> Subject: [vtkusers] Newbie Java question (yet another)
>
> Hi folks,
> Though I've trawled the archives, I can't seem to find anyone who has had
> this problem (or at least needed help sorting it out). I am trying to get
> the Java interface working under NT4, and though I can compile and run the
> Test.java code, compiling the sphere.java test doesn't work. I get the
> following errors:
>
> sphere.java:28: Class vtk.vtkPanel not found in type declaration.
> vtk.vtkPanel renPanel = new vtk.vtkPanel();
> ^
> sphere.java:28: Class vtk.vtkPanel not found in type declaration.
> vtk.vtkPanel renPanel = new vtk.vtkPanel();
> ^
> 2 errors
>
> I have tried compiling vtkPanel and vtkPanel.class is in the same directory
> as sphere.java, and my classpath points to the current directory as well as
> vtk.jar and classes.zip. This vtkPanel was in vtk31/java but there appears
> to be another vtkPanel in vtk31/vtk31/java/vtk alongside a
> vtkPanelBeans.java (I do not understand the directory tree at all). The
> only difference I can see between them is comments around the three
> Windows/X11 display lines. But what is the PanelBeans for?
>
> Any tips would be much appreciated!
>
> Confusedly,
>
> greg
>
> Greg Johnson, Design Engineer
> CLRC Rutherford Appleton Laboratory, Chilton, UK
> g.johnson at rl.ac.uk -- www.clrc.ac.uk
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at:
> <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
--
J.A. Lee
Software Engineer
Computational Dynamics North America
More information about the vtkusers
mailing list