The first step is implementing the clippin algorithm itself. In this image, the drawing was done by the native browser canvas API. Shown is a gray rectangle in the back, the source triangle. Red lines show the defined clipping planes. In white, the clipped triangle can be seen, which is a part cut out of the original gray triangle
The secont step is integrating the clipping algorithm into the rasterizer. In this image, the drawing was done with the current rasterizer. Red lines show the defined clipping planes. In white, the clipped triangle can be seen, which is a part cut out of the original triangle
The final step is extending the clipping algorithm to lines, which is just a simplified version of the one for triangles. Because of that, this ist just discussed without an exercise in the course. In this image, the drawing was done with the current rasterizer. Red lines show the defined clipping planes. In white, the clipped triangle can be seen, which is a part cut out of the original triangle Other red lines are shown which are clipped as well. As the rasterizer right now can only show one color per primitive, hese lines are also red
Rasterization course 04: sibaku.github.io/site/rasteri... We add arbitrary clipping planes! It's not fully needed right now, but we also just implemented line clipping! So we do it now, before adding some huge new features! We'll also use this feature without change in 3D! #math #computergraphics