MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches
Projection.hpp File Reference

NDC-to-value mappings, inverse to the forward placement performed by geometry functions. More...

#include "Bounds.hpp"
+ Include dependency graph for Projection.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  MayaFlux
 Main namespace for the Maya Flux audio engine.
 
namespace  MayaFlux::Kinesis
 

Functions

std::function< float(glm::vec2)> MayaFlux::Kinesis::angle_fraction (AABB2D region, float angle_start, float angle_end) noexcept
 angle_fraction centred on a region.
 
std::function< float(glm::vec2)> MayaFlux::Kinesis::angle_fraction (glm::vec2 center, float angle_start, float angle_end) noexcept
 Fraction along an angular sweep about center.
 
std::function< float(glm::vec2)> MayaFlux::Kinesis::axis_fraction (AABB2D bounds, float handle_extent=0.F, bool horizontal=true) noexcept
 Fraction along one axis of bounds, inverse to fader placement.
 
std::function< float(glm::vec2)> MayaFlux::Kinesis::path_fraction (std::span< const glm::vec2 > points)
 Normalized arc-length position of the closest point on a polyline.
 
std::function< float(glm::vec2)> MayaFlux::Kinesis::scaled (std::function< float(glm::vec2)> norm, float lo, float hi)
 Rescale a normalized projection onto an arbitrary range.
 
std::function< glm::vec2(glm::vec2)> MayaFlux::Kinesis::unit_square (AABB2D bounds) noexcept
 Unit-square coordinates of a point within bounds.
 

Detailed Description

NDC-to-value mappings, inverse to the forward placement performed by geometry functions.

Each function returns a callable suitable for direct use as the projection argument of Portal::Forma::Geometry::wire_drag. They are pure: no window, no context, no element. A projection paired with the geometry function that shares its parameters is what makes a control draggable.

Definition in file Projection.hpp.