Пример #1
0
 static public int BindBetween(this int item, IntRange range)
 {
     return(item.BindBetween(range.x1, range.x2));
 }
Пример #2
0
 static public bool IsBoundBetween(this int item, IntRange range)
 {
     return(item.IsBoundBetween(range.x1, range.x2));
 }
Пример #3
0
 static public IntRange GetFlipped(this IntRange item)
 {
     return(new IntRange(item.x2, item.x1));
 }
Пример #4
0
 static public int GetBetween(IntRange range)
 {
     return(SOURCE.GetBetween(range));
 }
Пример #5
0
 static public IntVariance GetVariance(this IntRange item)
 {
     return(new IntVariance(item.GetCenter(), item.GetRadius()));
 }
Пример #6
0
 static public int GetWidth(this IntRange item)
 {
     return((int)(item.x2 - item.x1));
 }
Пример #7
0
 static public int GetRadius(this IntRange item)
 {
     return((int)(item.GetWidth() / 2));
 }
Пример #8
0
 static public int GetCenter(this IntRange item)
 {
     return((int)((item.x1 + item.x2) / 2));
 }
Пример #9
0
 public int GetBetween(IntRange range)
 {
     return(GetBetween(range.x1, range.x2));
 }