[vtkusers] Problems with test.java

Philip Cook pacook at blueyonder.co.uk
Sat Jun 16 22:33:03 EDT 2001


> Message: 2
> From: "Matthew O'Brien" <matthew_obrien at ndsu.nodak.edu>
> To: <vtkusers at public.kitware.com>
> Date: Thu, 14 Jun 2001 17:34:40 -0500
> charset="Windows-1252"
> Subject: [vtkusers] Problem running test.java
> 
> 
> I have just completed an installation of vtk on a linux machine. I have run
> the Mace.cxx and Cone.tcl examples without any issues; however, when I try
> to run the Test.java program found on the website
> (http://public.kitware.com/vtkhtml/exampleCode.html) I ecounter a problem.
> It compiles without any problems, and when it runs, it opens a new window.
> But, there is no sphere in the window and the background color is not
> changed to white.
> 
> I'm using jdk1.3.0_02.
> 
> Has this happened to anyone else?
> 
> Thanks,
> Matt

I couldn't make that code compile on my (Win98) system. So I 
peeked at vtkPanel.java and found that the method 
vtkPanel.GetRenderer() called in test.java was actually 
vtkPanel.getRenderer().

On line 39 of test.java, try replacing 

	vtkRenderer ren1 = renPanel.GetRenderer();

with

	vtkRenderer ren1 = renPanel.getRenderer();




More information about the vtkusers mailing list