MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ rect_outline()

MAYAFLUX_API std::array< Kakshya::LineVertex, 8 > MayaFlux::Kinesis::rect_outline ( AABB2D region,
glm::vec4 color = glm::vec4(1.F),
float thickness = 1.F )
nodiscard

Rectangle outline as a LINE_LIST (4 edges, 8 vertices).

Parameters
regionNDC axis-aligned bounds.
colorUniform line color.
thicknessLine thickness.

Definition at line 327 of file Geometry2D.cpp.

329{
330 const glm::vec2 bl { region.min.x, region.min.y };
331 const glm::vec2 br { region.max.x, region.min.y };
332 const glm::vec2 tl { region.min.x, region.max.y };
333 const glm::vec2 tr { region.max.x, region.max.y };
334
335 return { {
336 lvert2(bl, color, thickness),
337 lvert2(br, color, thickness),
338 lvert2(br, color, thickness),
339 lvert2(tr, color, thickness),
340 lvert2(tr, color, thickness),
341 lvert2(tl, color, thickness),
342 lvert2(tl, color, thickness),
343 lvert2(bl, color, thickness),
344 } };
345}

References MayaFlux::Kinesis::AABB2D::max, and MayaFlux::Kinesis::AABB2D::min.

Referenced by MayaFlux::Portal::Forma::Geometry::handle_path().

Here is the caller graph for this function: