1
0
Fork 0

Codefix: Remove const from int parameters.

pull/13515/head
Peter Nelson 2025-02-15 14:07:27 +00:00
parent 4dceb9d8fc
commit 6816923448
No known key found for this signature in database
GPG Key ID: 8EF8F0A467DF75ED
1 changed files with 2 additions and 2 deletions

View File

@ -192,7 +192,7 @@ struct BlobHarmonic {
* @param harmonics Harmonics data for the polygon. * @param harmonics Harmonics data for the polygon.
* @param[out] shape Shape to fill with points. * @param[out] shape Shape to fill with points.
*/ */
static void CreateStarShapedPolygon(const int radius, std::span<const BlobHarmonic> harmonics, std::span<Point> shape) static void CreateStarShapedPolygon(int radius, std::span<const BlobHarmonic> harmonics, std::span<Point> shape)
{ {
float theta = 0; float theta = 0;
float step = (M_PI * 2) / std::size(shape); float step = (M_PI * 2) / std::size(shape);
@ -251,7 +251,7 @@ static void CreateRandomStarShapedPolygon(int radius, std::span<Point> shape)
* @param v3 Third vertex of triangle. * @param v3 Third vertex of triangle.
* @returns true if the given coordinates lie within a triangle. * @returns true if the given coordinates lie within a triangle.
*/ */
static bool IsPointInTriangle(const int x, const int y, const Point &v1, const Point &v2, const Point &v3) static bool IsPointInTriangle(int x, int y, const Point &v1, const Point &v2, const Point &v3)
{ {
const int s = ((v1.x - v3.x) * (y - v3.y)) - ((v1.y - v3.y) * (x - v3.x)); const int s = ((v1.x - v3.x) * (y - v3.y)) - ((v1.y - v3.y) * (x - v3.x));
const int t = ((v2.x - v1.x) * (y - v1.y)) - ((v2.y - v1.y) * (x - v1.x)); const int t = ((v2.x - v1.x) * (y - v1.y)) - ((v2.y - v1.y) * (x - v1.x));