ScratchData LogoScratchData
Back to Howtomakeausername's profile

Super fast z-clipping algorithm

HOHowtomakeausername•Created February 24, 2021
Super fast z-clipping algorithm
126
98
2253 views
View on Scratch

Instructions

WASDQE, ARROWS. This is a super fast way to do 3d z-clipping of 3d triangles. It only needs one triangle if two of the points are behind the camera but needs two if only one is (because it needs to fill a quad). I have set the z-clipping distance high for the demo, it should realistically be from ~1-10.

Description

All me :D Feel free to use but with credit! This is how it works - if two points are behind the camera it clips those two points but if one is I clip it with both the other points and fill a quad between the four points. Tags: #z #clipping #3d #triangle #filler #renderer

Project Details

Project ID492093390
CreatedFebruary 24, 2021
Last ModifiedNovember 4, 2023
SharedFebruary 26, 2021
Visibilityvisible
CommentsAllowed