# BoundsChecking File Reference

`#include <osg/Notify>`

Include dependency graph for BoundsChecking:

This graph shows which files directly or indirectly include this file:

## Namespaces

namespace | osg

## Defines

#define | OSG_BOUNDSCHECKING 1

## Functions

template<class T>
void | clampGEQUAL (T &value, const T minValue, const char *valueName)
| If value is greater than or equal to minValue do nothing - legal value, Otherwise set value to minValue, and warn that valueName was clamped.
template<class T>
void | clampLEQUAL (T &value, const T maxValue, const char *valueName)
| If value is less than or equal to maxValue do nothing - legal value, Otherwise set value to maxValue, and warn that valueName was clamped.
template<class T>
void | clampBetweenRange (T &value, const T minValue, const T maxValue, const char *valueName)
| If value is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp value to specified range and warn that valueName was clamped.
template<class A, class T>
void | clampArrayElementGEQUAL (A &value, unsigned int i, const T minValue, const char *valueName)
| If value[i] is greater than or equal to minValue do nothing - legal value, Otherwise set value[i] to minValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArrayElementLEQUAL (A &value, unsigned int i, const T maxValue, const char *valueName)
| If value[i] is less than or equal to maxValue do nothing - legal value, Otherwise set value[i] to maxValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArrayElementBetweenRange (A &value, unsigned int i, const T minValue, const T maxValue, const char *valueName)
| If value[i] is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp value[i] to specified range and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArrayElementsGEQUAL (A &value, unsigned int first, unsigned int last, const T minValue, const char *valueName)
| For each element of value[] in the range (first,last), if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArrayElementsLEQUAL (A &value, unsigned int first, unsigned int last, const T maxValue, const char *valueName)
| For each element of value[] in the range (first,last), if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArrayElementsBetweenRange (A &value, unsigned int first, unsigned int last, const T minValue, const T maxValue, const char *valueName)
| For each element of value[] in the range (first,last), if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray3GEQUAL (A &value, const T minValue, const char *valueName)
| For each element of the three-element array value[], if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray3LEQUAL (A &value, const T maxValue, const char *valueName)
| For each element of the three-element array value[], if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray3BetweenRange (A &value, const T minValue, const T maxValue, const char *valueName)
| For each element of the three-element array value[], if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray4GEQUAL (A &value, const T minValue, const char *valueName)
| For each element of the four-element array value[], if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray4LEQUAL (A &value, const T maxValue, const char *valueName)
| For each element of the four-element array value[], if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.
template<class A, class T>
void | clampArray4BetweenRange (A &value, const T minValue, const T maxValue, const char *valueName)
| For each element of the four-element array value[], if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped.

## Define Documentation

#define OSG_BOUNDSCHECKING 1

## Function Documentation

template<class A, class T>
void clampArray3BetweenRange | ( | A & | value,
|  | const T | minValue,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the three-element array value[], if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped. Equivalent to calling clampArray3GEQUAL( value, minValue, valueName); clampArray3LEQUAL( value, maxValue, valueName);

template<class A, class T>
void clampArray3GEQUAL | ( | A & | value,
|  | const T | minValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the three-element array value[], if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.

template<class A, class T>
void clampArray3LEQUAL | ( | A & | value,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the three-element array value[], if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.

template<class A, class T>
void clampArray4BetweenRange | ( | A & | value,
|  | const T | minValue,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the four-element array value[], if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped. Equivalent to calling clampArray4GEQUAL( value, minValue, valueName); clampArray4LEQUAL( value, maxValue, valueName);

template<class A, class T>
void clampArray4GEQUAL | ( | A & | value,
|  | const T | minValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the four-element array value[], if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.

template<class A, class T>
void clampArray4LEQUAL | ( | A & | value,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of the four-element array value[], if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.

template<class A, class T>
void clampArrayElementBetweenRange | ( | A & | value,
|  | unsigned int | i,
|  | const T | minValue,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| If value[i] is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp value[i] to specified range and warn that valueName[i] was clamped. Equivilant to calling clampArrayElementGEQUAL( value, i, minValue, valueName ); clampArrayElementLEQUAL( value, i, maxValue, valueName );

template<class A, class T>
void clampArrayElementGEQUAL | ( | A & | value,
|  | unsigned int | i,
|  | const T | minValue,
|  | const char * | valueName
| ) | `[inline]`

| If value[i] is greater than or equal to minValue do nothing - legal value, Otherwise set value[i] to minValue, and warn that valueName[i] was clamped. Note this is effectively A[i]=max(A[i],B).

template<class A, class T>
void clampArrayElementLEQUAL | ( | A & | value,
|  | unsigned int | i,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| If value[i] is less than or equal to maxValue do nothing - legal value, Otherwise set value[i] to maxValue, and warn that valueName[i] was clamped. Note this is effectively A[i]=min(A[i],B).

template<class A, class T>
void clampArrayElementsBetweenRange | ( | A & | value,
|  | unsigned int | first,
|  | unsigned int | last,
|  | const T | minValue,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of value[] in the range (first,last), if the element is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp the element to the range and warn that valueName[i] was clamped. Equivalent to calling clampArrayElementsGEQUAL( value, first, last, minValue, valueName); clampArrayElementsLEQUAL( value, first, last, maxValue, valueName);

template<class A, class T>
void clampArrayElementsGEQUAL | ( | A & | value,
|  | unsigned int | first,
|  | unsigned int | last,
|  | const T | minValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of value[] in the range (first,last), if the element is greater than or equal to minValue do nothing - legal value, Otherwise clamp the element to minValue, and warn that valueName[i] was clamped.

template<class A, class T>
void clampArrayElementsLEQUAL | ( | A & | value,
|  | unsigned int | first,
|  | unsigned int | last,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| For each element of value[] in the range (first,last), if the element is less than or equal to maxValue do nothing - legal value, Otherwise clamp the element to maxValue, and warn that valueName[i] was clamped.

template<class T>
void clampBetweenRange | ( | T & | value,
|  | const T | minValue,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| If value is between or equal to minValue and maxValue do nothing - legal value, Otherwise clamp value to specified range and warn that valueName was clamped. Equivilant to calling clampGEQUAL( value, minValue, valueName ); clampLEQUAL( value, maxValue, valueName );

template<class T>
void clampGEQUAL | ( | T & | value,
|  | const T | minValue,
|  | const char * | valueName
| ) | `[inline]`

| If value is greater than or equal to minValue do nothing - legal value, Otherwise set value to minValue, and warn that valueName was clamped. Note this is effectively A=max(A,B).

template<class T>
void clampLEQUAL | ( | T & | value,
|  | const T | maxValue,
|  | const char * | valueName
| ) | `[inline]`

| If value is less than or equal to maxValue do nothing - legal value, Otherwise set value to maxValue, and warn that valueName was clamped. Note this is effectively A=min(A,B).