TriEngine  v0.0.16
General-purpose engine in C#/OpenGL
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events
TriDevs.TriEngine.Extensions.FloatExtensions Class Reference

Extensions for System.Single. More...

Static Public Member Functions

static float Clamp (this float value, float min, float max)
 Clamps the specified float between a minimum and maximum value. More...
 

Detailed Description

Extensions for System.Single.

Member Function Documentation

static float TriDevs.TriEngine.Extensions.FloatExtensions.Clamp ( this float  value,
float  min,
float  max 
)
static

Clamps the specified float between a minimum and maximum value.

Parameters
valueValue to clamp.
minIf the specified float is below this value, then this will be returned.
maxIf the specified float is above this value, then this will be returned.
Returns
The clamped value of the float.
39  {
40  return Helpers.Math.Clamp(value, min, max);
41  }

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following file: