SlideShare une entreprise Scribd logo
1  sur  10
Télécharger pour lire hors ligne
The Visualization Toolkit (VTK)
  and why you might care about it

           Jiahao Chen
           May 8, 2007
Why VTK?
• More control than regular application
• You don’t need to care about hardware-
  and OS-specific details, e.g.
  – OpenGL vs. Mesa
  – X Windows vs. DirectX
VTK abstracts away details

                  does,
visualize data             (Your Program Here)
                   e.g.
                                      talks to
                  does,                             example of
                            Application Library
calc. contour                                                       VTK
                   e.g.
                                      talks to
                                                  example of
                    does,
                             Graphics Library
draw a triangle                                                  OpenGL
                     e.g.
                                      talks to
                   does,
                            OS, hardware etc.
add numbers         e.g.
How VTK works
• Stage 1: Visualization Model
  – What data to show?
  – How to visualize?
  – Converts data into 3D graphical elements
• Stage 2: Graphics Model
  – What needs to be drawn?
  – Where to draw it?
  – Converts abstract graphical elements into a
    displayed picture
Stage 1: Visualization Model
• Abstract objects handle data flow


    Source                                  Mapper
                            Filter


    raw data          data processing   how to draw things
                                          makes actors
 e.g. to draw an orbital,
  Point cloud   Construct isosurface    Triangle strips
Stage 2: Graphics Model
                              Trans-            Mapper
                               form
• Rendering pipeline
• Data flow between                                      Scene
                                                Actor
  objects
                                viewpoint
• Implemented as C++
  objects                       Camera
                                                         Light
• Wrappers for Java,
  Python and Tcl                      Props
                               where to
                                            Renderer
                              draw things

                                     “canvas”
                                       Render Window
                   end user
Execution Control
          End user
                                     • Visualization model is
                           5. User
                                       demand driven
                           happy

                                       – Data processed from
                4. draws
1. “Show me
                graphics
 the money!”                             source only when
                                         needed to
     Graphics Model
                                     • Graphics model is
                3. creates
     2. “ok,
                                       event driven
                graphics
 now what?”
                                       – Draws only when user
   Visualization Model                   wants it
VisTraj
• Want to see how if trajectories from FMS
  dynamics ever come close to model (ideal)
  cone computed from CI point parameters
• Want to visualize spawning events
• Example data: 12 trajectories around an
  ethylidene intersection in ethylene
VisTraj.py data flow
                                     FMSTrajectory                       simulation parameters
ModelCone
                        instance    ConicalIntersection used to calculate
      h vector
                            of
      numpy.array                          ModelCone

                                                                            ProjectedMomenta
      g vector                        Trajectory        Population
                                                                               vtkDoubleArray[3]
      numpy.array                     numpy.array       vtkDoubleArray

   Configuration                      Energies           Coupling           ProjectedTrajectory
           Molecule                   numpy.array       vtkDoubleArray             vtkPoints
    ConeActor                                                               attribute InputData
                                                     GlyphActor
       vtkQuadric
                                                                             data in vtkPolyData
                                                      vtkConeSource
  vtkSampleFunction
                                                        vtkGlyph3D
    vtkContourFilter
                                                        vtkPolyData
                                                                              SparkActor
  vtkPolyDataMapper
                                                    vtkPolyDataMapper
        vtkActor                                                             vtkSphereSource
                                                          vtkActor
                                                                            vtkPolyDataMapper
Molecule                                                                         vtkActor

                                                               Axes
Structure instance
                            Main Display                     vtkAxesActor
                                                                                     Outline
numpy.array
              of               vtkRenderer
                                                                                  vtkOutlineSource
 Energy                     vtkRenderWindow
                                                           props in              vtkPolyDataMapper
                        vtkRenderWindowInteractor
   float                                                                              vtkActor
                              vtkPNGWriter
Plot: 1 parent and 1 child
no attribute data
                                               child
                                     Spawn
    X
                                      point
           ProjectedTrajectory
                     vtkPoints

                    GlyphActor
                  vtkSphereSource
                     vtkGlyph3D
                     vtkPolyData
                 vtkPolyDataMapper
                       vtkActor
   InputData
                    TubeActor
   vtkPolyData
                     vtkPolyData
                    vtkTubeFilter
                 vtkPolyDataMapper
                       vtkActor


                                              parent
     Origin = 2CI

Contenu connexe

Similaire à The Visualization Toolkit (VTK) and why you might care about it

Hybrid Apps (Native + Web) via QtWebKit
Hybrid Apps (Native + Web) via QtWebKitHybrid Apps (Native + Web) via QtWebKit
Hybrid Apps (Native + Web) via QtWebKit
Ariya Hidayat
 
Shape12 6
Shape12 6Shape12 6
Shape12 6
pslulli
 
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
Alexandre Morgaut
 

Similaire à The Visualization Toolkit (VTK) and why you might care about it (20)

No Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time JavaNo Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time Java
 
Vtk Image procesing
Vtk Image procesingVtk Image procesing
Vtk Image procesing
 
Vtk file
Vtk   fileVtk   file
Vtk file
 
Analyzing the Performance of Mobile Web
Analyzing the Performance of Mobile WebAnalyzing the Performance of Mobile Web
Analyzing the Performance of Mobile Web
 
Android RenderScript on LLVM
Android RenderScript on LLVMAndroid RenderScript on LLVM
Android RenderScript on LLVM
 
vert.x - asynchronous event-driven web applications on the JVM
vert.x - asynchronous event-driven web applications on the JVMvert.x - asynchronous event-driven web applications on the JVM
vert.x - asynchronous event-driven web applications on the JVM
 
Instrumenting the real-time web
Instrumenting the real-time webInstrumenting the real-time web
Instrumenting the real-time web
 
Hybrid Apps (Native + Web) via QtWebKit
Hybrid Apps (Native + Web) via QtWebKitHybrid Apps (Native + Web) via QtWebKit
Hybrid Apps (Native + Web) via QtWebKit
 
Wakanda: NoSQL & SSJS for Model-driven Web Applications - SourceDevCon 2012
Wakanda: NoSQL & SSJS for Model-driven Web Applications - SourceDevCon 2012Wakanda: NoSQL & SSJS for Model-driven Web Applications - SourceDevCon 2012
Wakanda: NoSQL & SSJS for Model-driven Web Applications - SourceDevCon 2012
 
FLAR Workflow
FLAR WorkflowFLAR Workflow
FLAR Workflow
 
[TECHCON 2019: MOBILE - iOS]4-1.ARKit, CoreML, Turi Create 삼형제
[TECHCON 2019: MOBILE - iOS]4-1.ARKit, CoreML, Turi Create 삼형제[TECHCON 2019: MOBILE - iOS]4-1.ARKit, CoreML, Turi Create 삼형제
[TECHCON 2019: MOBILE - iOS]4-1.ARKit, CoreML, Turi Create 삼형제
 
Cocoa Design Patterns
Cocoa Design PatternsCocoa Design Patterns
Cocoa Design Patterns
 
12 Monkeys Inside JS Engine
12 Monkeys Inside JS Engine12 Monkeys Inside JS Engine
12 Monkeys Inside JS Engine
 
Conflict Resolution In Kai
Conflict Resolution In KaiConflict Resolution In Kai
Conflict Resolution In Kai
 
NoSQL and JavaScript: a love story
NoSQL and JavaScript: a love storyNoSQL and JavaScript: a love story
NoSQL and JavaScript: a love story
 
Windows Azure Interoperability
Windows Azure InteroperabilityWindows Azure Interoperability
Windows Azure Interoperability
 
Introducing spring
Introducing springIntroducing spring
Introducing spring
 
Shape12 6
Shape12 6Shape12 6
Shape12 6
 
Multi Client Development with Spring
Multi Client Development with SpringMulti Client Development with Spring
Multi Client Development with Spring
 
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
Wakanda: NoSQL for Model-Driven Web applications - NoSQL matters 2012
 

Dernier

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Dernier (20)

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 

The Visualization Toolkit (VTK) and why you might care about it

  • 1. The Visualization Toolkit (VTK) and why you might care about it Jiahao Chen May 8, 2007
  • 2. Why VTK? • More control than regular application • You don’t need to care about hardware- and OS-specific details, e.g. – OpenGL vs. Mesa – X Windows vs. DirectX
  • 3. VTK abstracts away details does, visualize data (Your Program Here) e.g. talks to does, example of Application Library calc. contour VTK e.g. talks to example of does, Graphics Library draw a triangle OpenGL e.g. talks to does, OS, hardware etc. add numbers e.g.
  • 4. How VTK works • Stage 1: Visualization Model – What data to show? – How to visualize? – Converts data into 3D graphical elements • Stage 2: Graphics Model – What needs to be drawn? – Where to draw it? – Converts abstract graphical elements into a displayed picture
  • 5. Stage 1: Visualization Model • Abstract objects handle data flow Source Mapper Filter raw data data processing how to draw things makes actors e.g. to draw an orbital, Point cloud Construct isosurface Triangle strips
  • 6. Stage 2: Graphics Model Trans- Mapper form • Rendering pipeline • Data flow between Scene Actor objects viewpoint • Implemented as C++ objects Camera Light • Wrappers for Java, Python and Tcl Props where to Renderer draw things “canvas” Render Window end user
  • 7. Execution Control End user • Visualization model is 5. User demand driven happy – Data processed from 4. draws 1. “Show me graphics the money!” source only when needed to Graphics Model • Graphics model is 3. creates 2. “ok, event driven graphics now what?” – Draws only when user Visualization Model wants it
  • 8. VisTraj • Want to see how if trajectories from FMS dynamics ever come close to model (ideal) cone computed from CI point parameters • Want to visualize spawning events • Example data: 12 trajectories around an ethylidene intersection in ethylene
  • 9. VisTraj.py data flow FMSTrajectory simulation parameters ModelCone instance ConicalIntersection used to calculate h vector of numpy.array ModelCone ProjectedMomenta g vector Trajectory Population vtkDoubleArray[3] numpy.array numpy.array vtkDoubleArray Configuration Energies Coupling ProjectedTrajectory Molecule numpy.array vtkDoubleArray vtkPoints ConeActor attribute InputData GlyphActor vtkQuadric data in vtkPolyData vtkConeSource vtkSampleFunction vtkGlyph3D vtkContourFilter vtkPolyData SparkActor vtkPolyDataMapper vtkPolyDataMapper vtkActor vtkSphereSource vtkActor vtkPolyDataMapper Molecule vtkActor Axes Structure instance Main Display vtkAxesActor Outline numpy.array of vtkRenderer vtkOutlineSource Energy vtkRenderWindow props in vtkPolyDataMapper vtkRenderWindowInteractor float vtkActor vtkPNGWriter
  • 10. Plot: 1 parent and 1 child no attribute data child Spawn X point ProjectedTrajectory vtkPoints GlyphActor vtkSphereSource vtkGlyph3D vtkPolyData vtkPolyDataMapper vtkActor InputData TubeActor vtkPolyData vtkPolyData vtkTubeFilter vtkPolyDataMapper vtkActor parent Origin = 2CI