Skip to content

Issue 220 block boundingbox #149

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 22, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Core/Internal/EntitiesHelper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -646,7 +646,7 @@ double EntitiesHelper::angle(const Utils::Entity* cec, const Utils::Entity* ce1,
bool EntitiesHelper::getBounds (const std::vector<Utils::Entity*>& entities, double bounds [6])
{
bounds [0] = bounds [2] = bounds [4] = std::numeric_limits<double>::max();
bounds [1] = bounds [3] = bounds [5] = std::numeric_limits<double>::min();
bounds [1] = bounds [3] = bounds [5] = std::numeric_limits<double>::lowest();
if (true == entities.empty ( ))
return false;

Expand Down
16 changes: 16 additions & 0 deletions test_link/test_free_bounded_topo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import pyMagix3D as Mgx3D
import pytest

def test_freeboundedtopo():
ctx = Mgx3D.getStdContext()
ctx.clearSession() # Clean the session after the previous test
gm = ctx.getGeomManager ()
tm = ctx.getTopoManager ()

gm.newVertex(Mgx3D.Point(-1.8, -.7, 1.2))
gm.newVertex(Mgx3D.Point(-.7, .45, -.1))
tm.newFreeBoundedTopoInGroup ("aaa", 3, ["Pt0000","Pt0001"])
c = tm.getCoord("Som0007")
assert c.getX() == -0.6999999
assert c.getY() == 0.4500001
assert c.getZ() == 1.2000001