Tải bản đầy đủ (.pdf) (43 trang)

Lecture computer graphics and virtual reality slides lesson 2 graphics systems

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (1.82 MB, 43 trang )

Lesson 2

Graphics systems

Trinh Thanh Trung

School of ICT, HUST


Content
1. Graphics pipeline
2. Graphics software
3. Graphics hardware


1.
Graphics pipeline


Object representation
■ To display an object to the screen…

Modeling

Rendering

Displaying


Modeling
■ Describing (to the computer)


□ What is a table, a car…

□ Concerned with:
▫ geometric info, color models, material property,
lighting property


Rendering
■ Draw the description
□ Create 2D image from 2D / 3D models

□ Concerned with:
▫ viewing & projection
▫ drawing & clipping primitives

▫ local illumination & shading
▫ texture mapping, global rendering


Displaying
■ Generate image on the screen
□ Concerned with:

▫ hardware
▫ rasterization


Graphics pipeline
■ Three stages
□ Application stage


□ Geometry stage
□ Rasterization stage


Application stage
■ Entirely done in software by the CPU
■ Load Data: world geometry, user’s input
■ In response to the user’s input, the application
stage change the view or scene


Geometry stage
■ Applying transformations to the object vertices
(scaling, rotating, translating)
■ View transformation (viewing from the camera)
■ Illumination and shading


Rasterization stage
■ Converting the continuous representation
(curves and lines) into the discrete representation
(pixels)
■ Anti-aliasing
■ Texture mapping
■ Bump mapping
■ Illumination and shading (per pixel)


Example scene



1. Modeling objects


Define polygons, parametric
curves/surfaces, etc. & its
own coordinate system


2. Model transformation


Applying translation, scaling and
rotation


3. Perspective projection


Convert from 3D coordinates to
2D coordinates


4. Hidden surface removal


Objects occluded by other objects
must not be drawn



5. Shading and lighting


Define the colour of each pixel


6. Rasterization


Convert vertex information
into pixel information



Anti-aliasing


7. Texture mapping


Map textures on objects


8. Others


Bump-mapping




Reflections



Shadows



×