feat: added sphere primitive

This commit is contained in:
2025-10-21 19:06:58 +03:00
parent 896f7876c1
commit 0db2cae1bb
7 changed files with 230 additions and 0 deletions

View File

@@ -42,6 +42,8 @@ public readonly struct Circle(Vector2D center, float radius) : IEquatable<Circle
public static bool operator ==(Circle left, Circle right) => left.Center == right.Center && left.Radius == right.Radius;
public static bool operator !=(Circle left, Circle right) => left.Center != right.Center || left.Radius != right.Radius;
public static implicit operator Circle(Sphere3D sphere) => new(sphere.Center, sphere.Radius);
/// <summary>
/// Sets the center of the <see cref="Circle"/>.
/// </summary>