Jump to content
  • Advertisement
Sign in to follow this  
white skies

Ok... changing strategy...

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

If you intended to correct an error in the post then please contact us.

Recommended Posts

Due to the fact that i'm having trouble with implementing the bezier surface, not understanding it completely and of course because openGL probably implemented it better than i can right now, I decided to implement only what i really need. :) Suppose you have initial control points of a bezier surface. You move one of the control points, let's say 1 units up, and the other control points move as well. Is there any way I can get the coordinates of the control points after the change? ( sorry if I'm starting/continuing to bother you...) As far as i understand, all i need to do is to calculate the correct bernstein function for this point... But what shuld the parameters be? Thanks:) [Edited by - white skies on April 27, 2005 11:28:57 AM]

Share this post


Link to post
Share on other sites
Advertisement
sorry if i came across harsh in your previous thread.

i misread your last post, i thought you were saying you did already understand it, which i found rahter arrogant, but you said you were simply trying to understand it.

my bad completely.

first, you should get straight: what do you really want?

ive tried to explain you to this before, and so have others, but let me try again. moving one controlpoint is as easy as changing its coordinate. this will not affect the other controlpoints, and neither should it. you want the other controlpoints to move? well, do so. they are not going to do so automaticly. what do you expect them to move to anyway? you move one, and the others automaticly take the shape of a bunny? a giraffe? none of that makes sense, since these control points cant guess what you want them to do, unless you tell them explicitly by just setting their position.

there is not much more i can do to help you now is to once again empathize the importance of understanding how beziers work and what they do before trying to use them for things they cant do, like reading your mind and knowing where you want them to go for instance.

search for the phrase 'bezier casteljeau step'. thinking of beziers that way is much more inituative than in terms of bernstein polynomals. and remember: the control points are the input, the surface is the output. while changing one controlpoint does affect the entire surface, it doesnt change the other controlpoints.

Share this post


Link to post
Share on other sites
Ok... so I guess what i'm looking for is the new intersection points of the lines in the grid, right?
they DO change, i'm not imagining it, right? at least i hope i'm not ;)
is there an algorithm for doing that?

Share this post


Link to post
Share on other sites
Not only is there an algorithm for finding points on the surface, but it has a name! It's called "Bezier". It's quite famous.

Your question is strangely surreal - could you explain what you are trying to do at a higher level, and perhaps then we can offer more help?

Share this post


Link to post
Share on other sites
I have a surface which i want to change, and some control points.
I want to keep drawing the control points on the intersections of the lines, no matter what changes to the surface are made.

Share this post


Link to post
Share on other sites
Quote:
Original post by white skies
I have a surface which i want to change, and some control points.
I want to keep drawing the control points on the intersections of the lines, no matter what changes to the surface are made.


oh! the lines!

uhm, wait... what lines?

Share this post


Link to post
Share on other sites
The time has come to set down some common ground :)

Bezier curve = curve defined by a set of control points
Mesh = bunch of triangles with vertices
Grid = bunch of interconnected nodes

OpenGL = graphics library which likes to draw approximations to a bezier curve by representing a discrete set of points on the curve as nodes in a grid, and then filling it in with triangles. This means that the vertices of the triangles correspond exactly to the nodes in the grid. The control points, in nearly all circumstances, will not.

Now, using that vocabulary, ask it a third time [wink]

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!