computer graphics 1
play

Computer Graphics 1 Ludwig-Maximilians-Universitt Mnchen Summer - PowerPoint PPT Presentation

Computer Graphics 1 Ludwig-Maximilians-Universitt Mnchen Summer semester 2020 Prof. Dr.-Ing. Andreas Butz lecture additions by Dr. Michael Krone, Univ. Stuttgart https://commons.wikimedia.org/wiki/File:Stanford_bunny_qem.png 1 LMU


  1. Computer Graphics 1 Ludwig-Maximilians-Universität München Summer semester 2020 Prof. Dr.-Ing. Andreas Butz lecture additions by Dr. Michael Krone, Univ. Stuttgart https://commons.wikimedia.org/wiki/File:Stanford_bunny_qem.png 1 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  2. Sources • This lecture was introduced by Michael Krone and is based on the slides of Filip Sadlo for the lecture „ Visualization in Science an Engineering “ • Course slides make use of selective contributions from • Thomas Ertl • Daniel Weiskopf • Carsten Dachsbacher • Oliver Deussen • Rüdiger Westermann • Stefan Gumbold • Dirk Bartz • Torsten Möller • Ronald Peikert 2 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  3. Chapter 10 – Volume Rendering & Scalar Field Visualization • Basic strategies • Function plots and height fields • Isolines • Color coding • Volume data • Overview of volume visualization approaches • Slicing • Indirect volume visualization • Direct volume rendering • Classification and segmentation 4 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  4. Basic Strategies • Visualization of 1D, 2D, or 3D scalar fields I R I R • 1D scalar field: Ω ⊂ → 2 • 2D scalar field: I R I R Ω ⊂ → 3 • 3D scalar field: I R I R → Volume visualization Ω ⊂ → 5 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  5. Basic Strategies • Mapping to geometry • Function plots • Height fields • Isolines and isosurfaces • Color coding • Specific techniques for 3D data • Indirect volume visualization • Direct volume visualization g Visualization method depends heavily on dimensionality of domain 6 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  6. Function Plots and Height Fields • Function plot for a 1D scalar field • Points {( s , f ( s )) | s I R } ∈ • 1D manifold: line • Error bars possible Gnuplot example 7 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  7. Function Plots and Height Fields • Function plot for a 2D scalar field 2 • Points {( s , t , f ( s , t ) | ( s , t ) I R } ∈ • 2D manifold: surface • Surface representations • Wireframe • Hidden lines • Shaded surface 8 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  8. Isolines • Visualization of 2D scalar fields • Given a scalar function f : I R � Ω and a scalar value (isovalue) c ∈ I R • Isoline consists of points {( x , y ) | f ( x , y ) c } = • If f () is differentiable and grad ( f ) ≠ 0, 
 then isolines are curves • Contour lines 9 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  9. Isolines 10 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  10. Isolines: Pixel-by-Pixel Contouring • Straightforward approach: 
 scanning all pixels for equivalence with isovalue • Input • f : (1,...,x max ) x (1,...,y max ) à R • Isovalues I 1 ,..., I n and isocolors c 1 ,...,c n • Algorithm for all (x,y) ∈ (1,...,x max ) x (1,...,y max ) do for all k ∈ { 1,...,n } do if |f(x,y)-I k | < ε then draw( x,y,c k ) • Problem: Isoline can be missed if the gradient of f() is too large (despite range ε ) 11 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  11. Isolines: Marching Squares • Representation of the scalar function on a uniform or rectilinear grid • Scalar values are given at each vertex f ↔ f ij • Take into account the interpolation within cells • Consider cells independently of each other 12 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  12. Isolines: Marching Squares • Which cells will be intersected ? • Initially mark all vertices by + or – , depending on the 
 conditions f ij ≥ c , f ij < c • No isoline passes through cells (=rectangles) which have the same sign at all four vertices • So we only have to determine the edges with different signs • And find the intersection point by linear interpolation + + + + y + + + + f(x) x c = [(f 2 -c )x 1 + (c-f 1 )x 2 ] / (f 2 -f 1 ) + – c,x c + + – + + – – – f 1 ,x 1 f 2 ,x 2 x x 13 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  13. Color Coding • Easy to apply to 1D and 2D scalar fields • Map color to each pixel on 1D or 2D image 2 3 I R I R Ω ⊂ → 14 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  14. Color Coding • Example: Medical images • Special color table to visualize the brain tissue • Special color table to visualize the bone structure Original Brain Tissue 15 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  15. Chapter 10 – Volume Rendering & Scalar Field Visualization • Basic strategies • Function plots and height fields • Isolines • Color coding • Volume data • Overview of volume visualization approaches • Slicing • Indirect volume visualization • Direct volume rendering • Classification and segmentation 16 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  16. Volume Data • Simple case: regular, rectilinear 3D grid with cubic cells • Stores one or more values per grid cell • Grid cell = voxel (volume pixel) • Data sources (examples) • Measurements, e.g., medical imaging (CT , MRT , 3D ultrasound…) • Simulation, e.g., fluid simulations (water, smoke, fog…) • Voxelization of 3D models, e.g., write closest distance to a surface to each voxel • Mathematical function 17 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  17. Volume Visualization • Scalar volume data 3 I R I R Ω ⊂ → • Medical Applications: • CT , MRI, confocal micros- 
 copy, ultrasound, etc. 18 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  18. Volume Visualization 19 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  19. Volume Visualization 20 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  20. Volume Visualization Approaches • Techniques for 2D scalar fields • Transform 3D data set to 2D • Then apply 2D methods • Indirect volume rendering techniques (e.g. surface fitting) • Convert/reduce volume data to an intermediate representation (surface representation), which can be rendered with traditional techniques • Direct volume rendering • Consider the data as a semi-transparent gel with physical properties and directly get a 3D representation of it 21 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  21. Volume Visualization Approaches • Slicing: 
 Slice Display the volume data, mapped 
 to colors, on a slice plane • Isosurfacing: 
 Generate opaque/semi-transparent 
 surfaces • Transparency effects: 
 Volume material attenuates 
 reflected or emitted light Semi-transparent 
 Isosurface material 22 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  22. Volume Visualization Approaches • 2D visualization 
 slice images 
 (or multi-planar 
 reformatting: MPR) • Indirect 
 3D visualization 
 isosurfaces 
 (or surface-shaded 
 display: SSD) • Direct 
 3D visualization 
 (direct volume 
 rendering: DVR) 23 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  23. Volume Visualization by Slicing • 2D visualization 
 slice images 
 (or multi-planar 
 reformatting: MPR) • Indirect 
 3D visualization 
 isosurfaces 
 (or surface-shaded 
 display: SSD) • Direct 
 3D visualization 
 (direct volume 
 rendering: DVR) 24 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  24. Volume Visualization by Slicing • 2D approach: Orthogonal slicing • Interactively resample the data on slices perpendicular to the x-,y-, z-axis • Use visualization techniques for 2D scalar fields • Color coding • Isolines • Height fields Slice 20 30 40 50 60 CT data set 25 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  25. Volume Visualization by Slicing • Alternative: Oblique slicing (MPR multiplanar reformating) • Resample the data on arbitrarily oriented slices • Resampling (interpolation) • e.g., exploit 3D texture mapping functionality 
 of OpenGL/Direct3D… • …or compute trilinear interpolation manually Image source: wikipedia 26 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  26. Volume Visualization by Slicing • 2D visualization 
 slice images 
 (or multi-planar 
 reformatting: MPR) • Indirect 
 3D visualization 
 isosurfaces 
 (or surface-shaded 
 display: SSD) • Direct 
 3D visualization 
 (direct volume 
 rendering: DVR) 27 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

  27. Isosurfaces: Examples 28 LMU München – Medieninformatik – Andreas Butz – Computergrafik 1 – SS2020

Recommend


More recommend