|
MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
|
|
inlinenoexcept |
Fraction along one axis of bounds, inverse to fader placement.
horizontal_fader and vertical_fader place the handle's leading edge at min + value * (extent - handle_extent), so the handle centre travels a span shorter than the track by one handle. This subtracts half a handle before dividing by the reduced span, so the handle centre tracks the cursor across the whole range rather than lagging by up to half a handle at the extremes.
Pass handle_extent of zero for mappings with no handle inset, such as a level_meter used as a scrub region.
| bounds | Track region in NDC. |
| handle_extent | Handle width for horizontal, height for vertical. |
| horizontal | True to map the x axis, false for y. |
Definition at line 37 of file Projection.hpp.
References MayaFlux::Kinesis::AABB2D::height(), MayaFlux::Kinesis::AABB2D::min, and MayaFlux::Kinesis::AABB2D::width().
Referenced by MayaFlux::Portal::Forma::Geometry::horizontal_fader(), and MayaFlux::Portal::Forma::Geometry::vertical_fader().
Here is the call graph for this function:
Here is the caller graph for this function: