[vtkusers] VTK + Java - Helpppp

Stephen mailinglists at icaril.eclipse.co.uk
Thu Aug 16 10:44:15 EDT 2007


Hi Marco,

I had some pains building certain versions from the cvs repository last 
year for Windows, but if you have a recent snapshot that shouldnt be a 
problem. However I did find the following guide helpful (thanks to Bartek).

Another thing you might consider is using precompiled libraries which I 
believe form part of the cassandra distribution.

http://www.vtk.org/pipermail/vtkusers/2006-December/088478.html

http://dev.artenum.com/projects/cassandra

regards

Stephen

Marco Aurelio Silva Neto wrote:

>Good Morning!!!
>
>	
>I use java + VTK with Netbeans. When I started to use
>the VTKPanel gave the following message of error: 
>
>undefined symbol: JAWT_GetAWT
>
>	
>Somebody can help me? It will be that error of
>compilation? What I must make?
>
>	
>Source code:
>
>package Esfera;
>
>import java.awt.BorderLayout;
>import java.awt.Frame;
>import javax.swing.JFrame;
>import vtk.vtkActor;
>import vtk.vtkConeSource;
>import vtk.vtkPanel;
>import vtk.vtkPolyDataMapper;
>
>public class Esfera{
>
>     static { 
> 	   System.loadLibrary("vtkCommonJava"); 
>           System.loadLibrary("vtkFilteringJava");
> 	   System.loadLibrary("vtkIOJava"); 
> 	   System.loadLibrary("vtkImagingJava"); 
> 	   System.loadLibrary("vtkGraphicsJava"); 
> 	   System.loadLibrary("vtkRenderingJava");
>           System.loadLibrary("vtkRendering");
>           System.loadLibrary("vtkpng");
>          // System.loadLibrary("libjawt.so");
>     }
>    public static void main(String[] args) 
>    { 
>
>        // Build the VTK 3D view 
>        // (Should be done before using any vtk 
>        // object or load the native 
>        // library first)
>        vtkPanel panel3D = new vtkPanel();
>
>        // Build a simple VTK pipeline
>        vtkConeSource coneSource = new
>vtkConeSource(); 
>        coneSource.SetRadius(2); 
>        coneSource.SetAngle(15);
>        coneSource.SetHeight(2);
>        coneSource.SetResolution(10);
>
>        vtkPolyDataMapper coneMapper = new
>vtkPolyDataMapper(); 
>        coneMapper.SetInput(coneSource.GetOutput());
>
>        vtkActor coneActor = new vtkActor();
>        coneActor.SetMapper(coneMapper);
>
>        // Add actor in 3D Panel
>        panel3D.GetRenderer().AddActor(coneActor);
>
>        // Build Java Frame and include the VTK view
>        JFrame frame = new JFrame("Artenum Demo");
>       
>frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); 
>        frame.getContentPane().setLayout(new
>BorderLayout());
>        frame.getContentPane().add(panel3D,
>BorderLayout.CENTER); 
>        frame.setSize(500, 500); 
>        frame.setLocationRelativeTo(null);
>
>        // Center on desktop 
>        frame.setVisible(true); 
>    }
>}
>
>
>      Flickr agora em português. Você clica, todo mundo vê.
>http://www.flickr.com.br/
>_______________________________________________
>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
>
>
>  
>





More information about the vtkusers mailing list