Presentation is loading. Please wait.

Presentation is loading. Please wait.

NA-MIC, 2008 June Workshop, IHK Akademie Westerham VTK

Similar presentations


Presentation on theme: "NA-MIC, 2008 June Workshop, IHK Akademie Westerham VTK"— Presentation transcript:

1 NA-MIC, 2008 June Workshop, IHK Akademie Westerham VTK
Sebastien BARRE, Ph.D. - Kitware, Inc.

2 VTK domain: Visualization
A definition for visualization Map data or information into images or other sensory input (touch, sound, smell, taste) Engages human perception system Simple, effective powerful Complex data Voluminous data NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

3 VTK: The Visualization Toolkit
Began with a textbook (work began 1993 – 1st edition 1995) NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

4 What is VTK? A visualization toolkit
Designed and implemented using object-oriented principles C++ class library (nearly 1,000,000 LOC) Automated Java, Tcl, Python bindings Portable across Unix, Windows, MacOSX Supports 2D/3D graphics, visualization, image processing, volume rendering, infoviz, geoviz 2500+ user mailing list; 40+ active developers World-wide academic, commercial, government users Basis of college undergraduate and graduate courses Free (BSD-like license) NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

5 VTK is not a system Embeddable Plays with other software Separable
Can pull out “pieces” Adaptable Not dependent on GUI Not dependent on rendering library NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

6 Building applications with VTK
Applications can be created using C++ (compiled language) Tcl (interpreted language) Java (interpreted language) Python (interpreted language) Interpreted Languages Have GUI support Easy to prototype with Slower than compiled C++ NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

7 DataSet types vtkRectilinearGrid vtkImageData vtkUnstructuredGrid
vtkStructuredGrid Structured data – vtkImageData (axis-aligned, even spacing per dimension), vtkRectilinearGrid (axis-aligned, irregular spacing allowed), vtkStructuredGrid (not axis-aligned, irregular spacing allowed – uses hexahedra or quads) Unstructured data – vtkPolyData (2D cells), vtkUnstructuredGrid (vtkPolyData + 3D cells) vtkPolyData NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

8 Examples NA-MIC, 2008 June Workshop, IHK Akademie Westerham

9 Surface rendering NA-MIC, 2008 June Workshop, IHK Akademie Westerham

10 Volume rendering NA-MIC, 2008 June Workshop, IHK Akademie Westerham

11 Image processing NA-MIC, 2008 June Workshop, IHK Akademie Westerham

12 Information visualization
NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

13 Interaction Widgets NA-MIC, 2008 June Workshop, IHK Akademie Westerham

14 The VTK graphics subsystem
Instances of render window (vtkRenderWindow)‏ Renderer instances (vtkRenderer)‏ Actor instances (vtkActor)‏ NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

15 The VTK graphics subsystem
A VTK scene consists of: vtkRenderWindow - contains the final image vtkRenderer - draws into the render window vtkActor - combines properties / geometry vtkLight - illuminate actors vtkCamera - renders the scene vtkPolyDataMapper - represents geometry vtkTransform - position actors NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

16 render window interactor
VTK « Hello world » sphere source polydata mapper actor renderer render window render window interactor NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

17 VTK « Hello world » (C++)
vtkSphereSource *sphere = vtkSphereSource()::New(); // create data pipeline vtkPolyDataMapper *sphereMapper = vtkPolyDataMapper::New(); sphereMapper->SetInputConnection(sphere->GetOutputPort()); vtkActor *sphereActor = vtkActor::New(); sphereActor->SetMapper(sphereMapper); //mapper connects actor with pipeline vtkRenderer *renderer = vtkRenderer::New(); vtkRenderWindow *renWin = vtkRenderWindow::New(); renWin->AddRenderer(renderer); vtkRenderWindowInteractor *iren = vtkRenderWindowInteractor::New(); iren->SetRenderWindow(renWin); renderer->AddViewProp(sphereActor); renderer->SetBackground(1,1,1); renWin->SetSize(300,300); renWin->Render(); iren->Start(); //starts the event loop NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008

18 Find more about VTK… Online documentation http://vtk.org Wiki FAQ
Manual pages (Generated by doxygen)‏ search the archive of the mailing lists Source code Embedded documentation in header files *.h Examples/ and Testing/ directories Books VTK Textbook VTK User's Guide NA-MIC, 2008 June Workshop, IHK Akademie Westerham June 16-17, 2008


Download ppt "NA-MIC, 2008 June Workshop, IHK Akademie Westerham VTK"

Similar presentations


Ads by Google