import java.awt.BorderLayout;

import javax.swing.JFrame;

import vtk.vtkActor;
import vtk.vtkConeSource;
import vtk.vtkDataSetMapper;
import vtk.vtkPanel;

public class TestVTK {
	public static void main(String[] args) {
		vtkPanel panel = new vtkPanel();
		//
		vtkConeSource source = new vtkConeSource();
		vtkDataSetMapper mapper = new vtkDataSetMapper();
		vtkActor actor = new vtkActor();
		//
		mapper.SetInput(source.GetOutput());
		actor.SetMapper(mapper);
		//
		panel.GetRenderer().AddActor(actor);
		//
		JFrame f = new JFrame("kljh");
		f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		f.setSize(500, 500);
		f.setLocationRelativeTo(null);
		f.getContentPane().setLayout(new BorderLayout());
		f.getContentPane().add(panel, BorderLayout.CENTER);
		f.setVisible(true);
	}
}
