mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 22:56:36 +09:00
Enforce readonly private members where possible.
This commit is contained in:
@ -8,10 +8,10 @@ namespace osu.Game.Modes.Objects
|
||||
{
|
||||
public class BezierApproximator
|
||||
{
|
||||
private int count;
|
||||
private List<Vector2> controlPoints;
|
||||
private Vector2[] subdivisionBuffer1;
|
||||
private Vector2[] subdivisionBuffer2;
|
||||
private readonly int count;
|
||||
private readonly List<Vector2> controlPoints;
|
||||
private readonly Vector2[] subdivisionBuffer1;
|
||||
private readonly Vector2[] subdivisionBuffer2;
|
||||
|
||||
private const float tolerance = 0.25f;
|
||||
private const float tolerance_sq = tolerance * tolerance;
|
||||
|
@ -10,9 +10,9 @@ namespace osu.Game.Modes.Objects
|
||||
{
|
||||
public class CircularArcApproximator
|
||||
{
|
||||
private Vector2 a;
|
||||
private Vector2 b;
|
||||
private Vector2 c;
|
||||
private readonly Vector2 a;
|
||||
private readonly Vector2 b;
|
||||
private readonly Vector2 c;
|
||||
|
||||
private int amountPoints;
|
||||
|
||||
|
@ -19,8 +19,8 @@ namespace osu.Game.Modes.Objects
|
||||
|
||||
public Vector2 Offset;
|
||||
|
||||
private List<Vector2> calculatedPath = new List<Vector2>();
|
||||
private List<double> cumulativeLength = new List<double>();
|
||||
private readonly List<Vector2> calculatedPath = new List<Vector2>();
|
||||
private readonly List<double> cumulativeLength = new List<double>();
|
||||
|
||||
private List<Vector2> calculateSubpath(List<Vector2> subControlPoints)
|
||||
{
|
||||
|
Reference in New Issue
Block a user