Unformatted text preview: iang-Barsky Clipping f (u) = (1 − u) · A + u · B For top boundary line of window: u= ymax − y1
y2 − y1 u∆y = ymax − y1 Define inequality to test for
‘visible side’ of boundary line upi ≤ qi
ECS 175 u∆y ≤ ymax − y1 One inequality for each edge Chapter 5: 3D – Projections, Camera, and Lighting 30 Liang-Barsky Clipping Line crosses
from invisible to
visible side of
boundary line ECS 175 Line crosses
from visible to
invisible side of
boundary line Trivial reject Chapter 5: 3D – Projections, Camera, and Lighting Line is inclusive 31 Polygon Clipping Shadows ECS 175 Chapter 5: 3D – Projections, Camera, and Lighting Concave polygons 32 Polygon Clipping
• Clipping can be described as black-box clipper ∆x
x3 = x1 + (ymax − y1 )
y3 = ymax (x1 , y1 ) (x2 , y2 ) ECS 175 Chapter 5: 3D – Projections,...
View Full Document
This document was uploaded on 03/12/2014 for the course ECS 175 at UC Davis.
- Spring '08