Advertisement

nth degre and 3rd degree beziers

Started by January 12, 2005 03:08 AM
4 comments, last by dawidjoubert 19 years, 10 months ago
hi there i have got the code for a nth degree bezier but i want one that interpolates an entire bezier as a 3rd degree even when i have like 7 points. Egg Point 1,3,5,7 will always be at the same place and then point 2,4,6 will be there tangent..... The reason is q3 uses 3rd degree ones even when a bezier is like 15*17 my second problem is i have controls[3][3] so i create interpolatelevel1[9][3] then i create true points[9][9] but yes that doesnt work think of it as interpolating the bezier twice and then its to smooth! Thanks
----------------------------

http://djoubert.co.uk
?! What ? Where ? Who ?
Speak more clearly , i didnt understand what was the first problem ....
Advertisement
yeah u know what i dont understand the problem either myself......

Could sum1 please give me the source code for a 3rd degree bezier and for a 3*3 bezier
----------------------------

http://djoubert.co.uk
If you want 3rd degree Bezier curves, but you have many points, just divide the points into smaller groups and attach them with seperate Bezier curves.
Quake 3 only draws 3x3 beziers, but they are stored in the bsp tree in huge lists. This is to cut down on the amount of space needed to store them (less faces). So, if you have a big patch that's 9x7, you render it in 3x3 chunks, like this:

o----|----o----|----o----|----o----|----o|  1 |  1 |  2 |  2 |  3 |  3 |  4 |  4 ||----|----|----|----|----|----|----|----||  1 |  1 |  2 |  2 |  3 |  3 |  4 |  4 |o----|----o----|----o----|----o----|----o|  5 |  5 |  6 |  6 |  7 |  7 |  8 |  8 ||----|----|----|----|----|----|----|----||  5 |  5 |  6 |  6 |  7 |  7 |  8 |  8 |o----|----o----|----o----|----o----|----o|  9 |  9 | 10 | 10 | 11 | 11 | 12 | 12 ||----|----|----|----|----|----|----|----||  9 |  9 | 10 | 10 | 11 | 11 | 12 | 12 |o----|----o----|----o----|----o----|----o


The o's represent the 3x3 patch corners.
thanks but now i have second thing,, i can get a bezier line of size 3 to do correctly but when i try to do it on a 3x3 it interpolation twice resulting in a smoother than normal curve......

i hope that makes sense.....


Quake 3 only draws 3x3 beziers, but they are stored in the bsp tree in huge lists. This is to cut down on the amount of space needed to store them (less faces). So, if you have a big patch that's 9x7, you render it in 3x3 chunks, like this:



o----|----o----|----o----|----o----|----o
| 1 | 1 | 2 | 2 | 3 | 3 | 4 | 4 |
|----|----|----|----|----|----|----|----|
| 1 | 1 | 2 | 2 | 3 | 3 | 4 | 4 |
o----|----o----|----o----|----o----|----o
| 5 | 5 | 6 | 6 | 7 | 7 | 8 | 8 |
|----|----|----|----|----|----|----|----|
| 5 | 5 | 6 | 6 | 7 | 7 | 8 | 8 |
o----|----o----|----o----|----o----|----o
| 9 | 9 | 10 | 10 | 11 | 11 | 12 | 12 |
|----|----|----|----|----|----|----|----|
| 9 | 9 | 10 | 10 | 11 | 11 | 12 | 12 |
o----|----o----|----o----|----o----|----o



The o's represent the 3x3 patch corners.


Yes that i understand that but is there a way that i generate those triangles by just using the noormal [7][9]Control 3dpoints instead of creating alot of new [3][3]Control 3dpoints


Thanks
----------------------------

http://djoubert.co.uk

This topic is closed to new replies.

Advertisement