Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

You have to clip against planes in 4D space (xyzw) before perspective divide (xyz /= w), not 3D (xyz).

This simplified sample shows Sutherland-Hodgman with 4D clipping: https://web.archive.org/web/20040713023730/http://wwwx.cs.un... The main difference is the intersect method finds the intersection of a 4D line segment against a 4D plane.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: