Bézier patch, similar to Bézier curve, is defined by a grid of control points. The grid can be of any size. The most common form of Bézier patch is bicubic Bézier surface patch, which uses a
Note: The bigger the grid, the more complex shapes we can make.
The Bézier patch is used in 3D modeling, such as Computer-aided design and computer graphics. It finds its applications in video games and animations.
The control points in the Bézier patch work as a magnet, pulling the surface of the patch towards them.
Each Bézier curve is made of
The shape of the surface is calculated based on the two parameters, named
You can think of
Each control point in the grid has a weight assigned to it based on the
The closer
To represent a Bézier patch, the equation used to calculate the position of a point on the surface at parameters
Where,
Note: Each row represents the coefficient of the control points.
The matrix for the control points of the surface patch is given below.
Once the weight for all the control points is calculated using the
Note:
The older points in the
matrix are then replaced by the newly calculated values of the points. All other matrices remain the same in the equation.
The
matrix contains all the updated values of the control points which is then used to draw the surface.
The de Casteljau algorithm is a technique used for evaluating points on a Bézier curve or Bézier surface patch. It is based on the de Casteljau algorithm, which recursively subdivides the control points of the curve or surface to calculate points at specific values.
For Bézier curves, the de Casteljau algorithm interpolates control points linearly and is a one-dimensional process. However, for Bézier patches, the de Casteljau algorithm extends it to a two-dimensional process, where points on the surface are interpolated in two directions:
The working of the de Casteljau algorithm is as follows.
In order to draw a surface, define a Bézier curve using the four control points.
Choose a value of
At the value of
Take these four values as the control points and define another 1D Bézier curve.
Choose the value of parameter
It will give you the point
Change the values of
Bézier patch have several important properties, some of which are explained below.
Interpolation: Bézier patch can interpolate their control points to ensure that the surface passes through each of the control point.
Convex hull property: The Bézier patch lies within the
Affine invariance: Bézier patches are invariant under
Local control: If we modify the position of one control point, it affects only a local portion of the Bézier patch. It allows each adjustments to specific parts of the surface without changing the entire shape.
Free Resources