Computer Graphics

Introduction

Prof. Dr. Ulrich Schwanecke

RheinMain University of Applied Sciences

🚀 by Decker

How to use the HTML slides

  • Use the keys left/right for navigating through the slides.
  • Click icon (top left) to open the navigation menu.
  • Press f/ESC to enter/leave fullscreen mode.
  • Double-click an item (e.g. an image) to zoom in/out.
  • If the bottom boundary flashes on slide change, something was written on the virtual whiteboard.
    • Scroll down to see it.

Acknowledgments

Many thanks to Mario Botsch!

About Computer Graphics

Computer Graphics vs. Computer Vision

image/svg+xml 3D model3D scene 2D image2D video ComputerGraphics ComputerVision ImageProcessing GeometryProcessing

Computer Graphics & Geometry Processing

images/geoproc.svg

Computer Graphics & Geometry Processing

images/geoproc-geometry.svg

Representation of Objects

  • Objects can be represented mathematically in different forms
    • Explict: \(y=\pm\sqrt{r^2-x^2}\)
    • Implicit: \(x^2+y^2-r^2=0\)
    • Parametric: \(\left(r\cdot\cos(t), r \cdot\sin(t)\right)^\top, t\in [0,2\pi)\)

images/ReprOfACircle.png

Triangle Meshes

  • Triangle meshes can represent arbitrary surfaces
images/vw.png

Triangle Meshes

  • Triangle meshes can represent arbitrary surfaces
  • Approximation error inversely proportional to #triangles
images/octagon-subdivision.png

Triangle Meshes

  • Triangle meshes can represent arbitrary surfaces
  • Approximation error inversely proportional to #triangles
  • Adaptive tessellation can adapt to surface curvature

images/adaptive-sampling-1.pngadaptive meshing images/adaptive-sampling-2.pngcurvature visualization

Triangle Meshes

  • Triangle meshes can represent arbitrary surfaces
  • Approximation error inversely proportional to #triangles
  • Adaptive tessellation can adapt to surface curvature
  • Simple primitives can efficiently be processed by CPU/GPU
images/graphics-card.png

Computer Graphics & Geometry Processing

images/geoproc-rendering.svg

Realistic Lighting Computations

images/spheres-0.pngcolor only images/spheres-1.png+diffuse images/spheres-2.png+specular

images/spheres-3.png+shadows images/spheres-4.png+reflections

Realistic Lighting Computations

images/cbox-0.pngshadows + reflection + refraction images/cbox-1.png+soft shadows

images/cbox-2.png+caustics images/cbox-3.png+indirect lighting

© Henrik Wann Jensen

Realistic Rendering for Movie Industry

images/gollum.pngLord of the Rings images/alita.jpgAlita Battle Angel

Realtime Rendering for Computer Games

images/farcry.pngFar Cry images/tombraider.jpgTomb Raider

Scientific Visualization

Visualization in Medical Imaging (Volume Rendering)

Computer Graphics & Geometry Processing

images/geoproc-modeling.svg

(Laser) Scanning

images/max-0.pngGet a nice model… images/scanner.gif…buy a laser scanner images/max-1.png…perform some scans images/max-2.png…and reconstruct a virtual model!

Cultural Heritage

images/david.pngDavid
1G sample points
images/saint-matthew.pngSt. Matthew
4G sample points

© Digital Michelangelo Project

Automotive Industry

images/bmw-0.pngReal model images/bmw-1.pngScanner point cloud images/bmw-2.pngReconstructed surface
images/bmw-3.pngFlow simulation

Avatar Generation

© Mario Botsch

Computer Graphics & Geometry Processing

images/geoproc-animation.svg

Motion Capturing & Character Animation

© Mario Botsch

Real-Time Motion Capturing

© Mario Botsch

Face Animation

Facial Animation by Linear Delta-Blendshapes

  • Facial expressions by blending example poses \[ \vec{x}_i \;=\; \vec{x}_i^{(0)} + \sum_{k=1}^n w_k \left( \vec{x}_i^{(k)} - \vec{x}_i^{(0)} \right) \]
    • Examples (blendshapes) have identical triangulation
    • Linear interpolation per vertex \(\vec{x}_i\)
    • Weights \(w_k\) typically are in \([0,1]\).
      (see what happens at 200% on Youtube)

Face Scanner at HSRM

images/Scanner/Scanner1_crop.png images/Scanner/Scanner3_crop.png images/Scanner/Scanner4_crop.png

16 synchronized 12MP, 30fps cameras

Expressions

Face Animation

Cloth Simulation

© Eitan Grinspun

Collisions

© Doug James

Elastic Deformations

Plasticity & Fracture

© Mark Pauly

Cutting Simulation

About this course

Course Goal and Content

  • Goal
    • Gain an understanding of the theoretical and practical concepts of computer graphics
  • After attending the course, you should be able to
    • understand the basic principles of image generation using local and global illumination
    • implement a rendering system based on real-time OpenGL or offline ray-tracing
    • know the pros/cons of the main geometry representations for 3D models or scenes
  • (Planned) Content (12 Lectures)
    1. Introduction, Organization
    2. Primitives, Transformations
    3. Raytracing
    4. Colors
    5. Lighting
    6. Rendering Equation
    7. Meshes
    8. 3D Transformations
    9. Projections
    10. Rasterization
    11. OpenGL
    12. Textures and Shadows

Organization

  • SWS 2V + 2Ü, 6 ECTS, Total Workload: 180h
  • Lecture
    • Thursday D14, 10:00-11:30
  • Exercise Sessions
    • Thursday D12, Group B: 11:45-13:15, Group A: 14:15-15:45
    • Friday D12, Group C: 14:15-15:45
    • Exercises are mandatory
    • Three evaluated assignments
  • Exam
    • Content: lectures and exercises
    • Very likely written (date and time will be announced)

Course Materials

Course Materials

  • Books (OpenGL)
    • J. Kessenich, G. Sellers, D. Shreiner, OpenGL Programming Guide, 9th edition, Addison-Wesley, 2016
      http://www.opengl-redbook.com
    • R. J. Rost, OpenGL Shading Language, 3rd edition, Addison-Wesley, 2009
    • R. S. Wright, N. Haemel, G. Sellers, B. Lipchak, OpenGL SuperBible: Comprehensive Tutorial and Reference, Addison Wesley, 2015
    • E. Angel, D. Shreiner, Interactive Computer Graphics with WebGL, Addison Wesley, 2015
  • Books (Curves and Surfaces)
    • G. Farin, Curves and Surfaces for CAGD: A Practical Guide, 5th edition, Morgan Kaufmann, 2002
  • Books (Matrices)

Course Materials

Prerequisites

  • Basic math skills
    • Linear Algebra
      • Vectors: \(\mathbf{x}, \mathbf{y} \in \mathbb{R}^n\)
      • Matrices: \(\mathbf{A}, \mathbf{B} \in \mathbb{R}^{m\times n}\)
      • Operations:
        • \(\mathbf{x}^\top\mathbf{y}, \mathbf{x}\times\mathbf{y}\), \(\mathbf{A}\mathbf{x}\)
        • \(\mathbf{A}^\top, \mathbf{A}^{-1}, \text{trace}(\mathbf{A}), \text{det}(\mathbf{A}), \mathbf{A}+\mathbf{B}, \mathbf{AB}\)
      • Norms: \(||\mathbf{x}||_1, ||\mathbf{x}||_2, ||\mathbf{x}||_\infty, ||\mathbf{A}||_F\)
      • Eigenvalues, Eigenvectors, SVD: \(\mathbf{A}=\mathbf{UDV}^\top\)
    • Calculus
      • (Multivariate) functions: \(f:\mathbb{R}^{n}\rightarrow \mathbb{R}\)
      • (Partial) derivatives: \(\frac{\partial f}{\partial x_i}, i=1,\ldots, n\), Gradient
      • Integrals: \(\int f(x)dx\)

Time Management


Activity Times Total
Attending (watching) the lecture 2h / week 24h
Self-study of lecture materials 2h / week 24h
Participation in exercise 2h / week 24h
Solving the assignments 6h / week 72h
Preparation for the final exam 36h 36h
Total workload 180h