fix typos (#556)

This commit is contained in:
John Vandenberg 2024-03-05 18:56:30 +08:00 committed by GitHub
parent f1bce9fd62
commit 91d821a1f2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 6 deletions

View File

@ -367,14 +367,14 @@ impl Contour {
return Contour::from_rect(rect);
}
let radius = radius.min(rect.size() * 0.5);
let contol_point_offset = radius * QUARTER_ARC_CP_FROM_OUTSIDE;
let control_point_offset = radius * QUARTER_ARC_CP_FROM_OUTSIDE;
let mut contour = Contour::with_capacity(8);
// upper left corner
{
let p0 = rect.origin();
let p1 = p0 + contol_point_offset;
let p1 = p0 + control_point_offset;
let p2 = p0 + radius;
contour.push_endpoint(vec2f(p0.x(), p2.y()));
contour.push_cubic(
@ -387,7 +387,7 @@ impl Contour {
// upper right
{
let p0 = rect.upper_right();
let p1 = p0 + contol_point_offset * vec2f(-1.0, 1.0);
let p1 = p0 + control_point_offset * vec2f(-1.0, 1.0);
let p2 = p0 + radius * vec2f(-1.0, 1.0);
contour.push_endpoint(vec2f(p2.x(), p0.y()));
contour.push_cubic(
@ -400,7 +400,7 @@ impl Contour {
// lower right
{
let p0 = rect.lower_right();
let p1 = p0 + contol_point_offset * vec2f(-1.0, -1.0);
let p1 = p0 + control_point_offset * vec2f(-1.0, -1.0);
let p2 = p0 + radius * vec2f(-1.0, -1.0);
contour.push_endpoint(vec2f(p0.x(), p2.y()));
contour.push_cubic(
@ -413,7 +413,7 @@ impl Contour {
// lower left
{
let p0 = rect.lower_left();
let p1 = p0 + contol_point_offset * vec2f(1.0, -1.0);
let p1 = p0 + control_point_offset * vec2f(1.0, -1.0);
let p2 = p0 + radius * vec2f(1.0, -1.0);
contour.push_endpoint(vec2f(p2.x(), p0.y()));
contour.push_cubic(

View File

@ -31,5 +31,5 @@ export SPIRVCROSS=spirv-cross.exe
Note: the Windows versions of `glslangValidator` and `spirv-cross` may change
the line endings of the generated output. Please take care to ensure that
unintended line ending changes aren't accidentally commited, for instance by
unintended line ending changes aren't accidentally committed, for instance by
[configuring Git to automatically handle line endings](https://docs.github.com/en/github/using-git/configuring-git-to-handle-line-endings#global-settings-for-line-endings).