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

◆ circular_bounds() [1/2]

std::function< bool(glm::vec2)> MayaFlux::Kinesis::circular_bounds ( glm::vec2  center,
float  radius 
)
inlinenoexcept

Containment test for a circle.

Parameters
centerNDC center.
radiusRadius in NDC units.

Definition at line 208 of file Bounds.hpp.

209{
210 float r2 = radius * radius;
211 return [center, r2](glm::vec2 p) {
212 glm::vec2 d = p - center;
213 return d.x * d.x + d.y * d.y <= r2;
214 };
215}

Referenced by MayaFlux::Portal::Forma::Geometry::crosshair(), MayaFlux::Portal::Forma::Geometry::point(), and MayaFlux::Portal::Forma::Geometry::radial().

+ Here is the caller graph for this function: