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

◆ centroid() [1/7]

glm::vec2 MayaFlux::Kinesis::centroid ( const Memory::HistoryBuffer< glm::vec2 > &  history,
size_t  window 
)
inlinenoexcept

Mean position across a window.

Parameters
historyBuffer of positions, capacity >= window
windowNumber of samples, minimum 1
Returns
Centroid of history[0..window-1]

Definition at line 523 of file Differential.hpp.

524{
525 return moving_average(history, window);
526}
std::weak_ptr< Core::Window > window
Definition Picker.cpp:23
T moving_average(const Memory::HistoryBuffer< T > &history, size_t window) noexcept
Simple moving average over the newest window samples.

References moving_average(), and window.

Referenced by centroid(), spread_radius(), and surface_centroid().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: