2
$\begingroup$

I hope this is the right group to be able to expose my doubts about the implementation of the algorithm shown in this article. The question I have is how to do the feature curves, what I do not understand is how to use piecewise Bézier cubic spline to build them. I hope someone can help me with an example please to be able to advance with that algorithm. Any help is welcome, thanks in advance.

$\endgroup$
  • $\begingroup$ Can you clarify? Do you not understand how piecewise Bézier cubic splines work? Or do you understand that, but not how to use them in this particular application? $\endgroup$ – user1118321 Dec 25 '17 at 6:50
  • $\begingroup$ @ user1118321 If I understand how Bezier cubic splines works, what I do not understand is the following. I'm trying to make a hill, what I do not know if it should be if it must have some points to make a curve, for example Q (16,137), S (64,198), T (112,137) and later add the parameters theta = Pi/4 and Phi = Pi/4 to build a feature curve of the hill. Could you tell me how steps 3.1 and 3.2 work, please, since I am very confused $\endgroup$ – bullitohappy Dec 26 '17 at 3:44
  • $\begingroup$ Could you edit your question to add the title and author of the paper you're linking? That'll make it easier for interested people to find your question, and it will help out anyone who can't access your link, or if the link dies. $\endgroup$ – Dan Hulme Jan 3 '18 at 9:27
1
$\begingroup$

The way I read it, you have a 2D cubic Bézier that defines the projections of the ridge line (or river bed, or whatever) onto the X/Y plane. In Figure 4, these are the dark purple lines.

So that gives you the direction that the ridge line moves. Now you have to define the height of the ridge line. This is done by picking some points along the 2D Bézier and setting the following values at each of the chosen points:

h = height
r = radius (this appears more like a width at the ridge line than a curved radius)

You can then also set the angle of the terrain as it comes off the radius. These are:

`phi` and `theta`
`a` and `b` are the lengths of the slopes

Keep in mind that you don't have to set every value for every control point you pick. I assume any you don't set are defaulted to 0, or some reasonable default.

So for a hill, you would set h to the height of the hill at a few point. You would then set phi and theta to be horizontal, so yes, pi / 4. The length of a and b will decide how quickly the hill falls off as you move away from the ridge line.

It looks like the above 6 values are turned into another cubic Bézier curve that is perpendicular to the first one for the rasterization step in section 4 of the paper. h doesn't factor into the shape of the perpendicular Bézier because it's also perpendicular to it. So r, theta, phi, a and b are used to make a cubic Bézier. I believe that you can think about like this: the point on the ridge line where you define one of these control points is the link between 2 cubic Bézier segments - one to the left of the point and the other to the right. The images they show only show a single point between 2 Bézier curves, but the way I'm reading it there are actually 2 curves that look something like this:

Beziers

So I think normally, you'd have 2 Béziers. One on each side of the control point they show in the paper. (Pardon my bad drawing.) a would be the distance between control points 2 and 3 of the left curve. Theta would be the angle formed between the vertical and a of the left curve. r would be the distance between points 3 and 4 of the left curve. I'm unclear on how one would pick control point 1 in this scenario, though.

Ai and Ri have to do with the noise parameters and don't appear to me to be related to the Bézier curves at all.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.