bevy/crates/bevy_math/src
jnhyatt 087a345579
Rename Bezier to CubicBezier for clarity (#9554)
# Objective

A Bezier curve is a curve defined by two or more control points. In the
simplest form, it's just a line. The (arguably) most common type of
Bezier curve is a cubic Bezier, defined by four control points. These
are often used in animation, etc. Bevy has a Bezier curve struct called
`Bezier`. However, this is technically a misnomer as it only represents
cubic Bezier curves.

## Solution

This PR changes the struct name to `CubicBezier` to more accurately
reflect the struct's usage. Since it's exposed in Bevy's prelude, it can
potentially collide with other `Bezier` implementations. While that
might instead be an argument for removing it from the prelude, there's
also something to be said for adding a more general `Bezier` into Bevy,
in which case we'd likely want to use the name `Bezier`. As a final
motivator, not only is the struct located in `cubic_spines.rs`, there
are also several other spline-related structs which follow the
`CubicXxx` naming convention where applicable. For example,
`CubicSegment` represents a cubic Bezier curve (with coefficients
pre-baked).

---

## Migration Guide

- Change all `Bezier` references to `CubicBezier`
2023-08-28 17:37:42 +00:00
..
rects Add reflect impls to IRect and URect (#9191) 2023-07-23 01:02:00 +00:00
affine3.rs Reduce the size of MeshUniform to improve performance (#9416) 2023-08-15 06:00:23 +00:00
cubic_splines.rs Rename Bezier to CubicBezier for clarity (#9554) 2023-08-28 17:37:42 +00:00
lib.rs Rename Bezier to CubicBezier for clarity (#9554) 2023-08-28 17:37:42 +00:00
ray.rs Improve code/comments for Ray::intersect_plane and its tests (#6823) 2022-12-05 22:49:06 +00:00