Presentation is loading. Please wait.

Presentation is loading. Please wait.

IN4151 Introduction 3D graphics 1 Introduction 3D Computer Graphics part 1 Projective display Viewing pipeline Graphics hardware Image-based rendering.

Similar presentations


Presentation on theme: "IN4151 Introduction 3D graphics 1 Introduction 3D Computer Graphics part 1 Projective display Viewing pipeline Graphics hardware Image-based rendering."— Presentation transcript:

1 IN4151 Introduction 3D graphics 1 Introduction 3D Computer Graphics part 1 Projective display Viewing pipeline Graphics hardware Image-based rendering

2 IN4151 Introduction 3D graphics 2 Polygon models x y z v1v1 v2v2 v3v3 v4v4 v5v5 v6v6 v7v7 v8v8 n Vertices defined with respect to world coordinate system with x,y,z coordinates o n x d

3 IN4151 Introduction 3D graphics 3 Viewing transformation x z y t Eye point Center of Projection Center of Interest w u v

4 IN4151 Introduction 3D graphics 4 d x' x O z Perspective transformation y z COP p p’ q q’ d x

5 IN4151 Introduction 3D graphics 5 Clipping Clipping after perspective transformation Take care of special cases (e.g. first remove points with negative z-coordinate)

6 IN4151 Introduction 3D graphics 6 Viewport transformation For standard case: Viewport / screen x vmax x vmin y vmax y vmin Window x wmax x wmin y wmax y wmin z depthrange z wmax z wmin

7 IN4151 Introduction 3D graphics 7 Rasterization Set-up increments along the edges Interpolate along edges and along spans Interpolate shading, normals, texture coordinates over span dx/dy dz/dx

8 IN4151 Introduction 3D graphics 8 Wire frame Backface removalHidden surface n Hidden-surface removal n view Backface: If (z < z depthbuffer ) then setpixel depthbuffer framebuffer

9 IN4151 Introduction 3D graphics 9 Shading Light interaction with surface is complex: –reflects diffusely-specularly –is absorbed, and partly re-emitted, changes color –is transmitted, and at different position re-emitted –approximations are needed

10 IN4151 Introduction 3D graphics 10 Phong model Diffuse reflection reflects light equally into all directions N L  L  R V Specular reflection reflects light around reflection direction Ambient term for indirect light

11 IN4151 Introduction 3D graphics 11 Reflection parameters 0.0 0.2 0.4 0.60.8 1.0 36925200 0.25 0.5 0.75 0.00.10.30.50.7

12 IN4151 Introduction 3D graphics 12 Gouraud shading To avoid faceted effect, calculate intensity at vertices and interpolate over facet normal at vertices are interpolated from normals of adjacent polygons faceted appearance smooth appearance (x 1,y 1 ) I 1 I 2 I 3 I 4 (x 2,y 2 ) (x 3,y 3 ) (x 4,y 4 ) I a I b (x a,y s ) (x b,y s ) (x s,y s ) I s

13 IN4151 Introduction 3D graphics 13 Texture mapping Texture mapping is a composed 2D perspective transformation Perspective projection maps “pre-image” in texture space to image space Filtering is required texture screen texture object screen u v x y pixel

14 IN4151 Introduction 3D graphics 14 Mipmap Mipmap is image pyramid with increasingly filtered/compressed images R G B R GB R GB u v d texture map polygon in perspective projection rasterized and textured

15 IN4151 Introduction 3D graphics 15 Anti-aliasing d ~  = + Special cases Alpha blending / compositing Point samplingArea sampling

16 IN4151 Introduction 3D graphics 16


Download ppt "IN4151 Introduction 3D graphics 1 Introduction 3D Computer Graphics part 1 Projective display Viewing pipeline Graphics hardware Image-based rendering."

Similar presentations


Ads by Google