Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... ·...
Transcript of Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... ·...
![Page 1: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/1.jpg)
Introduc)on to Computer Graphics
4/11/13
![Page 2: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/2.jpg)
Agenda
• Mo)va)on / Applica)ons • Graphics Pipeline • Shading & Aliasing • Other interes)ng topics • Conclusion
4/11/13 2
![Page 3: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/3.jpg)
Computer Graphics is about anima)on (films)
4/11/13 3
Major driving force now
![Page 4: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/4.jpg)
Games are very important in Computer Graphics
4/11/13 4
![Page 5: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/5.jpg)
Medical Imaging is another driving force
4/11/13 5
![Page 6: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/6.jpg)
Computer Aided Design
4/11/13 6
![Page 7: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/7.jpg)
Scien)fic Visualisa)on
4/11/13 7
To view below and above our visual range
![Page 8: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/8.jpg)
Graphics / Rendering Pipeline • Graphics processes generally execute sequen)ally
• Pipelining the process means dividing it into stages
• Especially when rendering in real-‐)me, different hardware resources are assigned for each stage
4/11/13 8
![Page 9: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/9.jpg)
Graphics / Rendering Pipeline • There are three stages
– Applica)on Stage – Geometry Stage – Rasteriza)on Stage
4/11/13 9
![Page 10: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/10.jpg)
Applica)on stage • En)rely done in soPware by the CPU • Read Data
– the world geometry database, – User’s input by mice, trackballs, trackers, or sensing gloves
• In response to the user’s input, the applica)on stage change the view or scene
4/11/13 10
![Page 11: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/11.jpg)
Geometry Stage
4/11/13 11
Model Transformation
Modeling: shapes
Shading: reflection and lighting
Transformation: viewing
Hidden Surface Elimination Rasterization Stage
![Page 12: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/12.jpg)
An example through the pipeline…
4/11/13 12
The scene we are trying to represent:
Images courtesy of Picture Inc.
![Page 13: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/13.jpg)
Preparing Shape Models
4/11/13 13
Designed by polygons, parametric curves/surfaces, implicit surfaces and etc.
Defined in its own coordinate system
![Page 14: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/14.jpg)
Model Transforma)on
4/11/13 14
l Objects put into the scene by applying translation, scaling and rotation
l Linear transformation called homogeneous transformation is used
l The location of all the vertices are updated by this transformation
![Page 15: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/15.jpg)
Perspec)ve Projec)on
4/11/13 15
l We want to create a picture of the scene viewed from the camera
l We apply a perspective transformation to convert the 3D coordinates to 2D coordinates of the screen
l Objects far away appear smaller, closer objects appear bigger
![Page 16: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/16.jpg)
Hidden Surface Removal
4/11/13 16
l Objects occluded by other objects must not be drawn
![Page 17: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/17.jpg)
Shading
4/11/13 17
l Now we need to decide the colour of each pixels taking into account the object’s colour, lighting condition and the camera position
Object
point light source
![Page 18: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/18.jpg)
Shading : Constant Shading -‐ Ambient
4/11/13 18
l Objects colours by its own colour
![Page 19: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/19.jpg)
Shading – Flat Shading
4/11/13 19
l Objects coloured based on its own colour and the lighting condition
l One colour for one face
![Page 20: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/20.jpg)
Gouraud shading, no specular highlights
4/11/13 20
l Lighting calculation per vertex
![Page 21: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/21.jpg)
Shapes by Polynomial Surfaces
4/11/13 21
![Page 22: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/22.jpg)
Specular highlights added
4/11/13 22
l Light perfectly reflected in a mirror-like way
![Page 23: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/23.jpg)
Phong shading
4/11/13 23
![Page 24: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/24.jpg)
Rasteriza)on Stage
4/11/13 24
Rasterization and Sampling
Texture Mapping
Image Composition
Intensity and Color Quantization
Geometry Stage
Framebuffer/Display
![Page 25: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/25.jpg)
Rasteriza)on • Converts the vertex informa)on output by the geometry pipeline into pixel informa)on needed by the video display
• Aliasing: distor)on ar)facts produced when represen)ng a high-‐resolu)on signal at a lower resolu)on.
• An)-‐aliasing : technique to remove aliasing
4/11/13 25
![Page 26: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/26.jpg)
An)-‐aliasing
4/11/13 26
Aliased polygons (jagged edges) Anti-aliased polygons
![Page 27: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/27.jpg)
4/11/13 27
ü How is anti-aliasing done? Each pixel is subdivided (sub-sampled) in n regions, and each sub-pixel has a color; ü Compute the average color value
![Page 28: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/28.jpg)
Texture mapping
4/11/13 28
![Page 29: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/29.jpg)
Other topics: Reflec)ons, shadows & Bump mapping
4/11/13 29
![Page 30: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/30.jpg)
Other topics: Global Illumina)on
4/11/13 30
![Page 31: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/31.jpg)
Conclusion
• Wide range of applica)ons • Op)mized in hardware • Classic approach gives good results • Open Research Topics
– Photorealism – Constrained devices – Real-‐)me
![Page 32: Introduc)on*to* Computer*Graphics*csce.uark.edu/~cwt/COURSES/2013-01--CSCE-5053--Adv... · Computer*Graphics*is*aboutanimaon*(films)* 4/11/13 3 Major driving force now . Games*are*very*importantin*Computer*Graphics*](https://reader036.fdocuments.in/reader036/viewer/2022071006/5fc3a84ce6a976220c03b29a/html5/thumbnails/32.jpg)
Ques)ons
?