MCPcopy Create free account
hub / github.com/Geode-solutions/OpenGeode / create_bounding_box

Function create_bounding_box

tests/geometry/test-aabb.cpp:37–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35
36template < geode::index_t dimension >
37geode::BoundingBox< dimension > create_bounding_box(
38 const geode::Point< dimension >& center, double box_size )
39{
40 geode::Point< dimension > temp;
41 for( const auto c : geode::LRange{ dimension } )
42 {
43 temp.set_value( c, box_size );
44 }
45 geode::BoundingBox< dimension > box;
46 box.add_point( center - temp );
47 box.add_point( center + temp );
48 return box;
49}
50
51template < geode::index_t dimension >
52std::vector< geode::BoundingBox< dimension > > create_box_vector(

Callers 2

create_box_vectorFunction · 0.85

Calls 2

set_valueMethod · 0.45
add_pointMethod · 0.45

Tested by

no test coverage detected