#include <OSGBaseTypeTraits.h>
Inheritance diagram for OSG::TypeTraits< Int8 >:

Public Types | |
| typedef Real32 | RealReturnType |
Static Public Member Functions | |
| static Int8 | getZeroElement (void) |
| static Int8 | getOneElement (void) |
| static Int8 | getMin (void) |
| static Int8 | getMax (void) |
| static Real32 | getFraction (Int8 val) |
| static Int8 | getPortion (Real32 val) |
| static Int8 | getFromCString (const Char8 *pData, Char8 *&pDataEnd) |
| static Int8 | getFromCString (const Char8 *pData) |
| static void | putToString (const Int8 val, std::string &out) |
| static void | putToStream (const Int8 &val, OutStream &str) |
Static Public Attributes | |
| static const bool | IsPOD = true |
| static const MathTypeProperties | MathProp = IntValue |
| static const Int8 | BitsSet = -1 |
| static const Int8 | BitsClear = 0x00 |
Definition at line 319 of file OSGBaseTypeTraits.h.
| typedef Real32 OSG::TypeTraits< Int8 >::RealReturnType |
Definition at line 321 of file OSGBaseTypeTraits.h.
| static Int8 OSG::TypeTraits< Int8 >::getZeroElement | ( | void | ) | [inline, static] |
| static Int8 OSG::TypeTraits< Int8 >::getOneElement | ( | void | ) | [inline, static] |
| static Int8 OSG::TypeTraits< Int8 >::getMin | ( | void | ) | [inline, static] |
| static Int8 OSG::TypeTraits< Int8 >::getMax | ( | void | ) | [inline, static] |
| static Real32 OSG::TypeTraits< Int8 >::getFraction | ( | Int8 | val | ) | [inline, static] |
Definition at line 352 of file OSGBaseTypeTraits.h.
00353 { 00354 return (Real32(val) / Real32(getMax())); 00355 };
| static Int8 OSG::TypeTraits< Int8 >::getPortion | ( | Real32 | val | ) | [inline, static] |
Definition at line 357 of file OSGBaseTypeTraits.h.
00358 { 00359 return (Int8) (val * Real32(getMax())); 00360 };
| static Int8 OSG::TypeTraits< Int8 >::getFromCString | ( | const Char8 * | pData, | |
| Char8 *& | pDataEnd | |||
| ) | [inline, static] |
Definition at line 363 of file OSGBaseTypeTraits.h.
00365 { 00366 if(pData != NULL) 00367 { 00368 return Int8(strtol(pData, &pDataEnd, 0)); 00369 } 00370 else 00371 { 00372 return getZeroElement(); 00373 } 00374 }
| static Int8 OSG::TypeTraits< Int8 >::getFromCString | ( | const Char8 * | pData | ) | [inline, static] |
Definition at line 376 of file OSGBaseTypeTraits.h.
00377 { 00378 Char8 *pDataEnd; 00379 00380 return getFromCString(pData, pDataEnd); 00381 }
| static void OSG::TypeTraits< Int8 >::putToString | ( | const Int8 | val, | |
| std::string & | out | |||
| ) | [inline, static] |
Definition at line 383 of file OSGBaseTypeTraits.h.
00385 { 00386 Char8 buffer[10]; 00387 00388 sprintf(buffer, "%i", val); 00389 00390 out.append(buffer); 00391 }
| static void OSG::TypeTraits< Int8 >::putToStream | ( | const Int8 & | val, | |
| OutStream & | str | |||
| ) | [inline, static] |
Reimplemented from OSG::TypeTraitsTemplateBase< Int8 >.
Definition at line 393 of file OSGBaseTypeTraits.h.
const bool OSG::TypeTraits< Int8 >::IsPOD = true [static] |
Definition at line 324 of file OSGBaseTypeTraits.h.
const MathTypeProperties OSG::TypeTraits< Int8 >::MathProp = IntValue [static] |
Definition at line 325 of file OSGBaseTypeTraits.h.
const Int8 OSG::TypeTraits< Int8 >::BitsSet = -1 [static] |
Definition at line 327 of file OSGBaseTypeTraits.h.
const Int8 OSG::TypeTraits< Int8 >::BitsClear = 0x00 [static] |
Definition at line 328 of file OSGBaseTypeTraits.h.