Skip to content

Average Velocity

eisclimber edited this page Apr 20, 2024 · 1 revision

Average Velocity

class in ExPresSXR.Movement / Extends MonoBehavior
Component added via Component Menu

Description

Calculates the average velocity of the component it is attached to.

Members

Editor Properties

  • int _numSamples: Number of position samples used to calculate the velocity. Default: 3

Public Methods

  • void SwitchMapPoint(MapPoint newMapPoint): Retrieves the current estimated velocity. Returns (0, 0, 0) if none and the GameObjects position if only one sample was gathered.
  • bool HasEnoughSamples(): Can be used to check if enough samples(=_numSamples) have been gathered to calculate the average velocity.

ExPresS XR Wiki

Tutorial Pages

Code Documentation

Clone this wiki locally