#### Archived

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

# Bezier patches [Tesselation]

This topic is 6173 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I''ve looked around for an efficient way to generate a trimesh from a bicubic bezier patch. I already have a brute force version that works but it''s everything but fast I saw over at NeHe that i should be possible to calculate four points along u and then use the new four points as control points for the curve along v (I hope I''m not too fuzzy. If you are unsure what I mean you can look at NeHes lesson 29 I have no doubts that this works but I question the accuracy in this method. The two middle control points of a bezier curve doesn''t have to lie on the curve but with the method above we use points that _are_ on the surface as control points? Doesn''t this give us the wrong surface points? Perhaps I''ve missed something along the way and this is the definition of a bezier patch or maybe I''m wrong all together.

##### Share on other sites
It isn't intuitive to me why it should be slow. There is a good deal of room for optimization without estimating. I don't know how you are calculating the grid, but you should do it as a x=u*mx*v, y=u*my*v and z=u*mz*v. u is a row vector calculated from the scalar u as and the same for v. mx is a 4X4 matrix of the x components of the control points and similarly for my and mz. Assuming you want an NXN grid then the scalar u and v vary by 1/(N-1). If you have to do this repeatedly you can can build a table with N entries. That table can be used to build both the row and column vectors. So now all you are doing in the loop as far as calculations are concerned is a row times a matrix times a column. I don't see at that point how estimating versus calculating makes much differance.

As for your original question the edges of a cubic bezier patch are cubic bezier curves made from four of the control points. So if u and v are your parameters then u=0 and u=1 with a fixed v that is 0 < v < 1 gives you the two end control points for a cubic bezier curve where u varies from 0 to 1, i.e. a grid line. The grid line passes through those points. I don't know how relavent that is to the document, but using estimates based off of points on the patch isn't necessarily wrong. The challenge is in figuring out where the other two control points are. I assume that is what is being estimated, but I don't see the point of that exercise. I could see the estimate saving you time over calculating where the effective control points would be, but not the advantage over just calculating the grid points.

Edited by - LilBudyWizer on October 25, 2001 2:39:29 PM

Edited by - LilBudyWizer on October 25, 2001 2:40:44 PM

1. 1
2. 2
3. 3
Rutin
22
4. 4
frob
16
5. 5

• 9
• 33
• 13
• 12
• 10
• ### Forum Statistics

• Total Topics
632575
• Total Posts
3007154

×