[vtkusers] java.lang.UnsatisfiedLinkError: VTKInit
Marie Bonhoure
mariebonhoure at hotmail.com
Mon Jul 9 09:19:24 EDT 2007
Yes, I have the vtk-dlls in my path. But I solved my problem by adding a
static block :
static {
System.loadLibrary("vtkCommonJava");
System.loadLibrary("vtkFilteringJava");
System.loadLibrary("vtkIOJava");
System.loadLibrary("vtkImagingJava");
System.loadLibrary("vtkGraphicsJava");
System.loadLibrary("vtkRenderingJava");
}
I don't know what difference it makes, but it works !!!
Thanks,
Marie Bonhoure
Ingénieur biomédical
Service de Neurochirurgie
HIA du Val de Grace
Tél bureau: 00 33 (0)1 40 51 4355
Tél secrétariat: 00 33 (0)1 40 51 4306
Fax: 00 33 (0)1 40 51 4332
>From: Lars Matthäus <lars.matthaeus at web.de>
>To: Marie Bonhoure <mariebonhoure at hotmail.com>
>Subject: Re: [vtkusers] java.lang.UnsatisfiedLinkError: VTKInit
>Date: Mon, 09 Jul 2007 22:10:04 +1000
>
>Do you have the vtk-dll's in your path?
>
>Marie Bonhoure schrieb:
> >
> > Hi,
> >
> > I'm using vtk with java (Eclipse) and I'm trying to run the following
> > code :
> >
> > package ex;
> >
> > import vtk.vtkDICOMImageReader;
> > import vtk.vtkImageViewer2;
> >
> > public class Test { public static void main(String[] args) {
> > vtkDICOMImageReader reader = new vtkDICOMImageReader();
> > System.out.println("après new vtkDICOMImageReader()");
> > vtkImageViewer2 viewer = new vtkImageViewer2();
> > viewer.SetInput(reader.GetOutput());
> > reader.SetDirectoryName("C:\\DATA\\s0");
> > reader.Update();
> > int VolData_Images = viewer.GetWholeZMax();
> >
> > for (int i = 0; i<= VolData_Images; i++) {
> > viewer.SetZSlice(i);
> > viewer.GetRenderer().ResetCameraClippingRange();
> > viewer.Render();
> > }
> > }
> > }
> >
> >
> > I get the following exception, which I don't understand because all my
> > paths are precised (vtk + java) :
> >
> > Exception in thread "main" java.lang.UnsatisfiedLinkError: VTKInit
> > at vtk.vtkDICOMImageReader.VTKInit(Native Method)
> > at vtk.vtkObject.<init>(vtkObject.java:90)
> > at vtk.vtkAlgorithm.<init>(vtkAlgorithm.java:246)
> > at vtk.vtkImageAlgorithm.<init>(vtkImageAlgorithm.java:58)
> > at vtk.vtkImageReader2.<init>(vtkImageReader2.java:234)
> > at vtk.vtkDICOMImageReader.<init>(vtkDICOMImageReader.java:90)
> > at ex.Test.main(Test.java:11)
> >
> > Any idea ??
> >
> > Thanks in advance.
> >
> >
> > Regards,
> >
> >
> > Marie Bonhoure
> > Ingénieur biomédical
> > Service de Neurochirurgie
> > HIA du Val de Grace
> > Tél bureau: 00 33 (0)1 40 51 4355
> > Tél secrétariat: 00 33 (0)1 40 51 4306
> > Fax: 00 33 (0)1 40 51 4332
> >
> > _________________________________________________________________
> > Découvrez le Blog heroic Fantaisy d'Eragon!
> > http://eragon-heroic-fantasy.spaces.live.com/
> >
> > _______________________________________________
> > This is the private VTK discussion list. Please keep messages on-topic.
> > Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> > Follow this link to subscribe/unsubscribe:
> > http://www.vtk.org/mailman/listinfo/vtkusers
> >
>
><< signature.asc >>
_________________________________________________________________
Personnalisez votre Messenger avec Live.com
http://www.windowslive.fr/livecom/
More information about the vtkusers
mailing list