Archived

This topic is now archived and is closed to further replies.

rodzilla

Rendering a triangular patch.

Recommended Posts

Does anybody have a good algorithm to render a triangular patch defined by 3 vertices and the associated normals ? I have found a whole lot of info about how to render rectangular patches defined using control points (including the *excellent* tut on NeHe''s page ;*), but nothing about triangular patches defined using normals. Thanx a lot in advance.

Share this post


Link to post
Share on other sites
OpenGL renders Bezier patches that are best used as rectangular. To render triangulate patches you can use degenerated Bezier patches.
Otherwise you still can implement your own algorithm, but this will obviously be slower to execute and longer to develop.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
ATI has something you might want to check out:
http://www.ati.com/developer/sdk/NPatch/NPatchViewer.zip

Share this post


Link to post
Share on other sites
Vincoof : do you mean I should use OpenGL evaluators to render the patch ?

Do you know where I can find *good* documentation about evaluators and how to degenerate a bezier quad ?

BTW I developped my own N-patch rendering function. Still have
to optimize it, but at least it works, and it is reasonably fast... Anyway, If I end up using evaluators, I''ll reuse the normals -> control points things ;*)

Share this post


Link to post
Share on other sites