MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / FromPoints

Method FromPoints

Source/Engine/Core/Math/BoundingBox.cpp:49–60  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47}
48
49void BoundingBox::FromPoints(const Float3* points, int32 pointsCount, BoundingBox& result)
50{
51 ASSERT(points && pointsCount > 0);
52 Float3 min = points[0];
53 Float3 max = points[0];
54 for (int32 i = 1; i < pointsCount; i++)
55 {
56 Float3::Min(min, points[i], min);
57 Float3::Max(max, points[i], max);
58 }
59 result = BoundingBox(min, max);
60}
61
62void BoundingBox::FromPoints(const Double3* points, int32 pointsCount, BoundingBox& result)
63{

Callers

nothing calls this directly

Calls 3

MinFunction · 0.70
MaxFunction · 0.70
BoundingBoxFunction · 0.70

Tested by

no test coverage detected