Ok... changing strategy...

Started by
16 comments, last by white skies 18 years, 11 months ago
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]
Advertisement
Would this be better off in the OpenGL forum? I can move it you want.
- The trade-off between price and quality does not exist in Japan. Rather, the idea that high quality brings on cost reduction is widely accepted.-- Tajima & Matsubara
They told me there wasn't any function that do this...
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.
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?
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?
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.
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?
I meant the bezier curves :)
My surface is made from a grid of curves (which are straight at first)
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]

This topic is closed to new replies.

Advertisement