1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-08 12:40:44 +00:00

[Core] Add scalar versions of Vector* min/max/clamp/snap(ped)

Convenience for a number of cases operating on single values
This commit is contained in:
A Thousand Ships
2024-03-03 14:37:52 +01:00
parent f91db3dc58
commit 308dbb8c63
73 changed files with 588 additions and 105 deletions

View File

@@ -55,7 +55,7 @@ Error QuickHull::build(const Vector<Vector3> &p_points, Geometry3D::MeshData &r_
HashSet<Vector3> valid_cache;
for (int i = 0; i < p_points.size(); i++) {
Vector3 sp = p_points[i].snapped(Vector3(0.0001, 0.0001, 0.0001));
Vector3 sp = p_points[i].snappedf(0.0001);
if (valid_cache.has(sp)) {
valid_points.write[i] = false;
} else {