MixedReality-WebRTC MixedReality-WebRTC
Search Results for

    Show / Hide Table of Contents

    Class MovingAverage

    Utility to manage a moving average of a time series.

    Inheritance
    Object
    MovingAverage
    Namespace: Microsoft.MixedReality.WebRTC
    Assembly: Microsoft.MixedReality.WebRTC.dll
    Syntax
    public class MovingAverage : object

    Constructors

    | Improve this Doc View Source

    MovingAverage(Int32)

    Create a new moving average with a given window size.

    Declaration
    public MovingAverage(int capacity)
    Parameters
    Type Name Description
    Int32 capacity

    The capacity of the sample window.

    Properties

    | Improve this Doc View Source

    Average

    Average value of the samples.

    Declaration
    public float Average { get; }
    Property Value
    Type Description
    Single
    | Improve this Doc View Source

    Capacity

    Number of samples in the moving average window.

    Declaration
    public int Capacity { get; }
    Property Value
    Type Description
    Int32

    Methods

    | Improve this Doc View Source

    Clear()

    Clear the moving average and discard all cached samples.

    Declaration
    public void Clear()
    | Improve this Doc View Source

    Push(Single)

    Push a new sample and recalculate the current average.

    Declaration
    public void Push(float value)
    Parameters
    Type Name Description
    Single value

    The new value to add.

    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX