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

Extensions for System.Byte. More...

Static Public Member Functions

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

Detailed Description

Extensions for System.Byte.

Member Function Documentation

static byte TriDevs.TriEngine.Extensions.ByteExtensions.Clamp ( this byte  value,
byte  min,
byte  max 
)
static

Clamps the specified byte between a minimum and maximum value.

Parameters
valueValue to clamp.
minIf the specified byte is below this value, then this will be returned.
maxIf the specified byte is above this value, then this will be returned.
Returns
The clamped value of the byte.
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: