shading for computer topics in burapha university

9
Presented by: Mr. Sararith Mao ID: 52031206 Computer Graphic Topic: Shading

Upload: chanrida-kim

Post on 15-Jul-2015

56 views

Category:

Art & Photos


2 download

TRANSCRIPT

Page 1: Shading for Computer Topics in Burapha University

Presented by:

Mr. Sararith Mao

ID: 52031206

Computer Graphic Topic:

Shading

Page 2: Shading for Computer Topics in Burapha University

Introduction to Shading

• Shading is a process used in drawing the levels of shadow of polygon by applying media with a darker shade for darker areas, and a lighter shade for lighter areas.

In this topic I will say about flat shading, flat shading, and phong shading

Page 3: Shading for Computer Topics in Burapha University

1. Flat shading

During scan conversion, the entire surface of one polygon has only one color. It is easy to compute and least accurate.

In Open GL, we can specify flat shading through glShadeModel(GL_FLAT).

Page 4: Shading for Computer Topics in Burapha University
Page 5: Shading for Computer Topics in Burapha University

2. Smooth or Gouraud shadingEvery vertices has its own normal. The

concept is that smooth shading compute each vertices during scan conversion and interpolate colors across all polygon pixels depends on the normal. This method is a superior of flat shading and require more processing, but less accurate to polygon. In OpenGL, we can define smooth shading by glShadeModel(GL_SMOOTH)

Page 6: Shading for Computer Topics in Burapha University

High polygon count. Poor polygon count.

Page 7: Shading for Computer Topics in Burapha University

It computes illumination for every pixel during scan conversion and also find the interpolate normal too. Although it’s hard to do, but the result of polygon is accurate than other methods. It’s not supported in Open GL directly.

3. Phong shading

Page 8: Shading for Computer Topics in Burapha University
Page 9: Shading for Computer Topics in Burapha University

Referrences:

• http://en.wikipedia.org/wiki/Phong_shading

• http://en.wikipedia.org/wiki/Gouraud_shading

• http://en.wikipedia.org/wiki/Shading