Calculates Bezier coefficients from a shape
Arguments
- coo
a matrix or a list of (x; y) coordinates
- n
the degree, by default the number of coordinates.
Note
Directly borrowed for Claude (2008), and also called bezier
there.
Not implemented for open outlines but may be useful for other purposes.
See also
Other bezier functions:
bezier_i()
Examples
set.seed(34)
x <- coo_sample(efourier_shape(), 5)
plot(x, ylim=c(-3, 3), asp=1, type='b', pch=20)
b <- bezier(x)
bi <- bezier_i(b$B)
lines(bi, col='red')