Questions tagged [bezier]
A Bézier curve is a parametric curve frequently used in computer graphics and related fields. Generalizations of Bézier curves to higher dimensions are called Bézier surfaces, of which the Bézier triangle is a special case.
1,223
questions
2
votes
1
answer
26
views
Splitting rational bezier
According to someone a rational bezier can be split by projecting its control points from 2d to 3d (or from 3d to 4d and so on), splitting the resulting non-rational curve with De Casteljau, and then ...
-2
votes
1
answer
27
views
Bezier curve, question for the new control point
For a Bezier curve I know the P0,P1 and the
control point P2. (and I can calculate the Q0)
I want to find for a new curve, with Q1(t=0,25) == Q0(t=0,25),
P0==Q0(t=0.25) and P1==Q0(t=0.75),
the new ...
2
votes
0
answers
34
views
Non overlapping random shapes on 2D plane
Objective: I want to create random non-overlapping irregular rounded shapes (contours) on a 2D plane, similar to a sandstone microstructure as shown below, to perform an oil flooding experiment using ...
1
vote
1
answer
69
views
How to draw a piecewise cubic spline in SVG
I receive a list of points from my layout engine (ELK) which I would like to convert to a SVG path.
I've got the following:
A start point
An end point
A list of bend points that "must be ...
0
votes
1
answer
47
views
Find control point on Quadratic Bezier Curve
I drew a Quadratic Bezier curve. Here A(0, 1.39) and B(30, 1.42) are two points and curves drawn with a single control point (15.02, 6.07).
I want to move point B along the curve. But When I move the ...
0
votes
1
answer
55
views
Scaling a bezier graph to starting and ending points
I have a graph like this:
And I want to be able to convert the position of P1 aka the ball you can drag around to scale with different starting and ending points on my screen.
I esentially want to ...
0
votes
1
answer
49
views
Perspective projection of rational bezier
I need a method to project 3d conics to 2d. None of the articles tell how to do this with rational beziers. Another thing I need a method for is moving 3d or 2d conics to 4d or 3d respectively (as in ...
4
votes
1
answer
49
views
Are Javafx ellipses and arcs genuine? Or just approximations?
I'm following the source code of OpenJFX. The PathIterator only supports SEG_LINETO, SEG_QUADTO, SEG_CUBICTO, which are lines and quadratic/cubic Bézier curves. ArcIterator and EllipseIterator returns ...
1
vote
1
answer
66
views
How to clear my BezierCurve vector to stop writing coordinates on top of each other?
I have built a Bezier Curve tool and each time the coordinates for each curve segment are calculated they are stored in a vector. Every single frame I am adding the entire curve's points on it over ...
0
votes
1
answer
34
views
Understanding Bezier derivation code that leads nowhere
I'm trying to convert Bezier.js implementation of calculating normals to a Shadertoy program, and the code appears to not use any of the calculated values. It needs to be for quadratic rationals as ...
0
votes
0
answers
43
views
How to extract Bezier curve equation from font with no "thickness"?
[EDIT]
I am working on a path-following problem where the path is described by the geometric path of letters from a font. Bezier curves will solve my problem of a predefined geometric path in terms of ...
2
votes
1
answer
55
views
How to scale a Bezier Curves t value while keeping its initial and final derivatives the same?
there are a lot of answers for scaling a bezier curve's position, but i want to scale its t value. I have found a solution for this, but the problem is once i scale my t value my velocity changes.
By ...
0
votes
1
answer
42
views
Bezier MxN Surface in matrix form( with Python and numpy)
I am trying to rewrite slow method("bezier_surf_eval") for bezier surface with quick one(in matrix form "bezier_surface_M").
Using this formula:
Were [N] and [M] an bezier basis ...
0
votes
3
answers
91
views
Scaling tangent lines in a bezier curve
I am currently working on a project about Bezier curves and their properties. I am struggling to understand a concept. I can't seem to understand why you need a scale for the tangent line in a Bezier ...
1
vote
0
answers
30
views
How should I calculate an entry-path from orbit, in 3D?
We can disregard aspects such as gravity, velocity and time. What I'm really looking for is a general concept of how to get from an Origin to a Destination in a manner that curves "nicely" ...
0
votes
0
answers
29
views
Distance from point to conic bezier
I'm trying to rasterize a conic (rational quadratic) bezier, and came across this snippet: https://www.shadertoy.com/view/MlKcDD The idea is to calculate the distance from each fragment to the bezier ...
3
votes
0
answers
50
views
Classifying cubic bezier curves according to Loop & Blinn 2005
I am trying flatten a bezier path (remove all intersections and replace with end points) as part of the implementation of the rendering algorithm described here and found the algorithm described by ...
0
votes
3
answers
141
views
How to get a better approximation of a thick bezier curve?
Let's say I already have a bezier curve approximated by many straight lines (the bezier array in the code), and I would like to draw it with a series of rectangles. I have the following code below ...
-1
votes
1
answer
24
views
Bezier curve, get consistent points on axis?
So I have a bezier curve >
Now, I would like to get a y point, value every says, 0.01 value on x-axis.
As far as I know, there is no method to "find Y given X" using bezier.
So I have to ...
1
vote
2
answers
214
views
How to create custom curved iOS UITabBar?
So this is the navigation my designer made for our project. Height of the TabBar is 70.
What I have tried so far.
My attempt was based on tutorial from Philipp Weiss.
https://betterprogramming.pub/...
0
votes
1
answer
123
views
Equation for the normal of a point on a Bezier curve?
I have recently been working on Bezier curves and have come across a very interesting snippet of code relating to finding the normal of a Bezier curve. It is the only of its kind I can find and there ...
2
votes
1
answer
133
views
Calculating exact animation delay
I am trying to animate an svg element as following
a. I want to increase the width of the rect and control the rate of animation speed with a cubic-beziervalue, in this case it is cubic-bezier(0, 0, 0....
1
vote
1
answer
60
views
Flutter : How to get a straight line using CustomClippers
I wanted to create the curved container like widget in the picture below
I used the Custom clipper class and created a similar one which is shown below
Below is the WaveClipper class I used to ...
1
vote
1
answer
46
views
How to create MATLAB code for making bilinear coon's surface patch from cubic Bezier curves
I have following data from which I need to create coon's patch. Matrix of polygon vertices given below:
P0u = \[0,0,0; 0.2357,0.2357,0.3333; 1.1785,0.2357,0.3333; 1.4142,0,0\];
P0w = \[1.4142,0,0; 1....
0
votes
1
answer
66
views
Create a curve using Flutter: Bezier Curve
I've created a custom clipper Bezier curve in flutter however the curve I've created is not smooth(No curve).
What I have now is this.
Code
class MyClipper extends CustomClipper<Path>{
@...
0
votes
0
answers
74
views
Python: draw an interactive line (arc) with the mouse on an image
I'm doing a Python program to fit Bezier curves to the eye contour (for example one curve that is adapted to the bottom line of the brow and the other to the lid's contour ). In order to achieve this, ...
0
votes
1
answer
70
views
Would like to generate surface of revolution from bezier curve
I would like to generate surface of revolution from bezier curve. I have made bezier curve in MATLAB but beyond this point I am stuck and do not know how to proceed. Please help.
Below is the code ...
0
votes
0
answers
18
views
Random shapes of haing equal area using Bezier curve
I am trying to generate random shapes of equal areas. I am following another post where random shapes are created https://stackoverflow.com/a/50751932/11078529
Is it possible to put a constraint like ...
2
votes
1
answer
83
views
How Can I Make a Thicker Bezier in Pygame?
I'm building a specialized node editor in Pygame. Each node will be connected with a bezier curve. This curve is built by clicking on a node first. A bezier is drawn between the mouse cursor and the ...
2
votes
1
answer
47
views
Changing the opacity of the polygons in the Python Bezier package
I want to change the opacity the polygon plots made with
this Python Bezier package.
Here is the code I tried:
import bezier
import matplotlib.pyplot as plt
import numpy
plt.clf()
nodes0 = numpy....
0
votes
0
answers
37
views
Incorrect result when saving Opensubdiv patches using Open Cascade
I am trying to save patches from OpenSubdiv subdivision using Open Cascade for one of my app that I am trying to build for subdivision surfaces. This is pretty similar to the thread - https://groups....
0
votes
0
answers
51
views
How to find bezier coefficients without matrices?
The function get_cubic needs 4 points and i need to find b and c by calculation (a and d is given).
Here is my code and i need help specifically with get_bezier_coef
def get_bezier_coef(points):
# ...
0
votes
1
answer
109
views
Rendering Lines with Bezier Curves in DX11
I want to input control points through the tessellation stages and output them as bent lines.
I expand the lines into billboarded quads in the geometry shader.
Right now I input a bunch of random ...
1
vote
0
answers
62
views
How to make the image distort with the control points of the curve?
This image consists of eight curves, and I obtained their control points and angles
by calculating:
var PI2=Math.PI*2;
var s={x:dis[i][0],y:dis[i][1]};
var c1={x:dis[i][2],y:dis[i][3]};
var c2={x:dis[...
0
votes
1
answer
102
views
Bezier curve... adding normals (in 3D)
I have a bezier curve class. Each point on the curve is defined thus:
struct bpoint
{
vector3D position;
vector3D controlpoint_in;
vector3d controlpoint_out;
};
To retrieve a point on ...
0
votes
0
answers
120
views
How do I get points(x,y,angle) for multiple cubic bezier curves?
Now the method I'm using can only get the points of one curve, because the second curve I don't know the start point,I tried to use the end point of the first curve to be the start point of the ...
1
vote
1
answer
49
views
ipycanvas displaying final stroke_lines thoughout animation
So I was playing with animating some Bezier curves - just part of learning how to use ipycanvas (0,10,2) -- The animation I produced is really hurting my head. What I expected to see was a set of ...
0
votes
2
answers
109
views
How to interpolate points of an N-dimensional vector using Bézier curves?
I created an audio spectrum visualizer and I need to change the position of the frequencies so that lower frequencies occupy more space than higher ones.
Because of this, there are spaces between of ...
7
votes
1
answer
146
views
Finding the shortest distance between a quadratic Bezier curve and point or rectangle
I am working on a simple whiteboard application where the drawings are represented by quadratic Bezier curves (using the JavaScript's CanvasPath.quadraticCurveTo function). I am trying to implement ...
2
votes
0
answers
89
views
Extrusion Effect For Bezier Curves In JS [closed]
is there a tool available for JS to perform a simple extrusion effect to composite cubic Bezier curves (which I will refer to as composite curves), like they are used in SVGs, similar to figure (5) in ...
8
votes
1
answer
2k
views
Native Android -> How to create custom curved bottom navigation
So this is the navigation my designer made for our project.
Height of the bottom navigation is 70dp.
What I have tried so far.
First I downloaded a vector drawable background from design and set it as ...
0
votes
1
answer
80
views
Ways to make bezier curves with about 8-9 control points in Javascript
I am making a game where i need to display ship traversing a flowing river. I am creating river with bezier curves but it is with only 3 control points from the bezerCurveTo. So, the river is not '...
0
votes
0
answers
79
views
UPDATED: CGAL How can I construct an edge between a vertex and the intersections of two beziers?
UPDTATE: For anyone else who find this question, and wants a solution.
After discussing this on the CGAL mailing list, it is clear that the vertex which is the intersections of two Bezier curves ...
2
votes
1
answer
63
views
How to add a texture to the stroke of a Bezier curve in an svg?
Not to fill a region bounded by a bezier curve and a line.
E.g. here's a very simple stroked Bezier curve
<?xml version="1.0" standalone="no"?>
<svg width="160" height="80" xmlns="http://...
1
vote
0
answers
470
views
How to create Bézier curve using Path in SwiftUI
I want to achieve a path like this in the picture using Path in SwiftUI, but my understanding of the Bezier curve is minimal, and I cannot reproduce the drawing on the image.
I am talking about the ...
2
votes
1
answer
96
views
Force zero normal acceleration at start/end of Bezier curve
Below I have attached a Python script that calculates a 5-point Bezier curve and calculates the normal acceleration of that curve. The result looks as follows:
We see on the right-hand side that the ...
5
votes
2
answers
298
views
How to move along a bezier curve with a constant velocity without a costly precomputation?
Forgive me for the long code example, but I couldn't figure out how to properly explain my question with any less code:
let c = document.querySelector("canvas");
let ctx = c.getContext("2d");
...
0
votes
1
answer
83
views
How to find the halfway mark on a bezier curve?
I am trying to calculate where points are on a bezier curve, and I'm using the standard formula for doing so. That is:
x = (1 - t) * (1 - t) * x1 + 2 * (1 - t) * t * cpX + t * t * x2;
y = (1 - t) * (1 ...
1
vote
2
answers
355
views
Trying to make a Bezier Curve on PyGame library
I started messing around with PyGame lately, so i tried making a bezier curve, however, it turns out the curve doesn't end on the points i would like to. Heres the code:
from pygame.locals import *
...
2
votes
1
answer
145
views
How to draw a fraction of a bezier curve with canvas?
Let's say I have a bezier curve produced from the following code:
const ctx = document.querySelector('canvas').getContext('2d');
ctx.beginPath();
ctx.moveTo(50, 20);
ctx.quadraticCurveTo(230, 30, ...