[vtkusers] vtk>=5.0 + java + mingw

Matthias Kern Kern.Matthias at gmx.de
Mon Sep 1 03:52:08 EDT 2008


I'm using vtk since a while now. So far I was using mainly C++.
Currently I developed a small Java apllication and wanted to add a chart using VTK.
That's where I run into trouble.
The fact that I use QT forces me to use the gcc compiler environment also under Windows XP.
Nevertheless compiling VTK with java wrapping switched on wasn't a problem using mingw.

After the compilation and after adding the bin path to %PATH% I opened the tutorial->step1->cone example and changed all vtk*Java libs to libvtk*Java and compiled the java code with classpath pointing to vtk.jar. No error messages. But running the code leads always to an error message at the first vtk instance complaining about a missing Init() function. I checked if the libs are loaded by adding try -> catch blocks to all loadSystem commands -> no error.

Well I tried version 5.0.4, 5.2 and the latest 5.3 using cmake 2.6 as well as 2.7. After some frustrating days I downloaded VC++. Compiled the code, installed it and run the Cone example -> without any problem.

The problem is that I use QT4 and don't want too have two versions of the VTK libs.
Has anybody managed to use the vtk libs compiled with mingw in java??? By the way I'm using java 1.6.0 update 7.

I would by very gratefull for any hint!
-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer



More information about the vtkusers mailing list