Subtracting shapes?

Started by
0 comments, last by GameDev.net 19 years, 2 months ago
suppose i wish to draw a cube with a cylindar hole in it... is it possible to do some sort of subtraction between a cube and a cylindar to get to proper result? i have heard of something like that before...
Advertisement
you can either do geometrically yourself and then just render the final result with opengl. search for constructive solid geometry(csg) for how to subtract one geometry from another.

or you can do image space csg using opengl's stencil buffer, like this: http://www.opencsg.org/

This topic is closed to new replies.

Advertisement