Previous | Next --- Slide 30 of 71
Back to Lecture Thumbnails
ShadyPastry

I just want to suggest changing the colors on this image. In lecture, I was extremely confused until you pointed out that there were 3 pixel colors, not just 2.

tplatina

I was a little bit confused about why the second small triangle on the top isn't cover any pixel since the left edge falls on two sample points.

motoole2

ShadyPastry: Changing colors is a good suggestion, to get around any potential dynamic range issues with the projector.

And good observation tplatina! This is an interesting case, because a vertex of the triangle exactly covers the center of the pixel; I'll focus on the vertex at the top row. There are in fact two edges overlapping the center of that pixel, where the edges connect at a common vertex. One edge is facing left (pixel should be on) and one edge is facing right (pixel should be off). So based on the top-left rule established in this slide, it's unclear whether to consider pixels within or outside the triangle in this specific situation. (This truly is a corner case.) Though I'm not sure of the exact procedure to use in this case, it appears as though the top-left rule must hold for both edges to turn on that pixel. There are actually several triangles in this example whose vertices overlap the center of pixels.

If you would like to read more about rasterization rules used in Direct3D, check this link.

uhhh

Just wondering, what is the logic behind using two cell shades for covered pixels?

motoole2

This is for illustrative purposes. The two cell shades helps distinguish which of the triangles covers a pixel. Only one triangle can cover the center of each pixel in this case.

qhy

How is "left edge" defined exactly?

motoole2

Suppose that \theta represents the orientation of an edge, \theta = 0 represents a top edge, and \theta = \pi / 2 represents a 90 degree counter-clockwise rotation (left edge). Then any edge where 0 <= \theta < \pi would satisfy this top-left rule.