Table of Contents

Method OpenSawTooth

Namespace
Gamelogic.Extensions.Algorithms
Assembly
Gamelogic.Extensions.dll

OpenSawTooth(int)

Makes a generator that produces evenly spaced floats from 0 (included) to 1 (excluded), and repeats the result.

public static IGenerator<float> OpenSawTooth(int sampleCount)

Parameters

sampleCount int

The number of samples per cycle.

Returns

IGenerator<float>

A new generator.

Exceptions

ArgumentOutOfRangeException

sampleCountis not positive.

OpenSawTooth(IGenerator<int>)

Makes a generator that produces evenly spaced floats from 0 (included) to 1 (excluded), and repeats the result (but with the number of samples each time given by a generator).

public static IGenerator<float> OpenSawTooth(IGenerator<int> sampleCount)

Parameters

sampleCount IGenerator<int>

The number of samples per cycle.

Returns

IGenerator<float>

A new generator.

Exceptions

ArgumentOutOfRangeException

sampleCountis not positive.