Clipping

What is the best way to clip objects before drawing?
I thought about clipping two volumes defined by arbitrary planes, but it appears to be too complicated.

If you’re using a nVidia card let the card do all the clipping. You should do object culling, backface culling and if you feel like it frustum culling.

I’m speaking about clipping geometry by frustum volume before sending to card.
I know how to clip one point(translate it to normalize device coordinates). But how to do this with more complex objects? Bound them by sphere? Or by box?

Originally posted by RandyU:
But how to do this with more complex objects? Bound them by sphere? Or by box?

What shape is the complex object? If it’s sort of round, then bound it with a sphere. If it’s long and thin, a box would be better (because a sphere would be much bigger than is optimal, to enclose a long thin object)

I’m implementing abstract class system, so I dont know what kind of objects will I have. I think I’ll bound them by convex multihedron defined by vertices. But I just have no idea how to check if it lies inside of viewing volume.

Being a frequent contributor, I’m surprised you haven’t come across this link before http://www.markmorley.com/opengl/frustumculling.html Should have everything you need.

Hope that helps.