Bezier curve(again): given Y, solve for X

  • Context: Undergrad 
  • Thread starter Thread starter abeall
  • Start date Start date
Click For Summary
SUMMARY

The discussion focuses on solving for X in a cubic Bezier curve defined by points p1, cp1, cp2, and p2 when Y is known. It is established that the curve intersects Y if p1 and p2 are on opposite sides of Y, while it does not intersect if all points are on the same side. The solution involves solving the cubic equation formed by the parametric equations x = f(t, C_x) and y = g(t, C_y), where C_x and C_y are the control points. Up to three solutions for t may exist, allowing for the calculation of X based on the determined t values.

PREREQUISITES
  • Understanding of cubic Bezier curves and their control points
  • Familiarity with parametric equations
  • Knowledge of solving cubic equations
  • Basic grasp of intersection analysis in curves
NEXT STEPS
  • Study the mathematical properties of cubic Bezier curves
  • Learn how to solve cubic equations using numerical methods
  • Explore the implications of parametric equations in curve intersections
  • Investigate graphical representations of Bezier curves for better visualization
USEFUL FOR

Mathematicians, computer graphics developers, and anyone involved in animation or modeling that requires understanding of Bezier curves and their properties.

abeall
Messages
21
Reaction score
0
In a http://en.wikipedia.org/wiki/B%C3%A9zier_curve" defined by p1, cp1, cp2, p2, is it possible to solve for X when Y is known?

I can't figure out how to determine if the bezier curve intersects Y. I can conclude that the bezier curve does intersect if p1 and p2 are either side of Y. I can conclude that the bezier curve does not intersect if p1, cp1, cp2, and p2 all fall on one side of Y, but in the case that p1 and p2 fall on one side, and one or both cp1 and cp2 fall on the other side of Y, I don't know, it may or may not intersect. Additionally, it may intersect 1, 2, or 3 times.

Beyond that, I don't know how to solve X when Y is know, or even if it is possible.

Thanks for any advice.
 
Last edited by a moderator:
Physics news on Phys.org
I think the situation is really the same as in your other thread - need to solve a cubic. In a cubic bezier, you have:

x = f(t,C_x)...C_x are the control points
y = g(t,C_y)...C_y are the control points

For the given y, you can solve the 2nd equation for t (0-3 solutions possible), then calculate x from the determined t.

In special cases, parametric equations can be combined (e.g. equation of a circle), but in general, it isn't possible because the curves can loop. That's what makes parametric equations so powerful.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 11 ·
Replies
11
Views
13K
  • · Replies 39 ·
2
Replies
39
Views
5K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 10 ·
Replies
10
Views
6K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K