Jump to content
  • Advertisement

Archived

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

Sagar_Indurkhya

Weighting a Bezier Surface

This topic is 5211 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

I am using a Bezier Surface to smooth out my terrain, which is based on Perlin Noise. Right now, I am going to put multiple control points at the same point, so the surface passes closer to the control point. I know this works with Bezier Curves. Will this work, or do I need to learn how to work with B-Splines. I don''t get the knot vector thingy. Thanks in advanced! Sagar Indurkhya PS: I''ve rigged my Equation so I can have any number of control points.

Share this post


Link to post
Share on other sites
Advertisement
I don''t personally know which is best, but two years ago for a graphics class project, I needed some random terrain for a animated raytraced (POV-Ray) scene, and I used natural cubic splines, since I had been learning about them in one of my math classes the same semester. They have the nice property of always passing exactly through each control point. I don''t remember much about the algorithm, unfortunately, but it had to do with filling in a large matrix (the size of which is based on the number of control points used), and then getting the matrix into reduced row echelon form. It was pretty funky looking code, but it worked quite nicely. And it can easily be adapted so that the two ends of the spline end up having the exact same slope and curvature, thus becoming a periodic cubic spline instead of a natural one (where the curvature is zero at the endpoints). There''s some resources on the internet, I''m sure, if you search, but unfortunately, I don''t remember finding any that were really easy to understand. I myself did a lot of fiddling around with pieces of code from various sites and from my text book, until I got the darn thing to work.

Share this post


Link to post
Share on other sites

  • 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!