Sign in to follow this  
ogl5

near-clip function

Recommended Posts

ogl5    100
I was wondering... is this a decent prototype for a near-clip function? vector<Triangle> NearClip(const Triangle& tri);

Share this post


Link to post
Share on other sites
jpetrie    13104
Presupposing that Triangle has all the data for the triangle and you have access to the clip plane somewhere... yes.

However, there is no reason why you need a separate function for each clip plane. The process is easily generalizable to a single function (perhaps with a few utility methods thrown in to reduce code duplication) for all planes. I can show you an example if you like.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this