Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

osg::TypeTraits< Real16 > Struct Template Reference
[BaseTypesTraits]

#include <OSGBaseTypeTraits.h>

Inheritance diagram for osg::TypeTraits< Real16 >:

osg::TypeTraitsBase List of all members.

Public Types

typedef Real16 RealReturnType

Static Public Member Functions

static Real16 getZeroElement (void)
static Real16 getOneElement (void)
static Real16 getMax (void)
static Real16 getMin (void)
static Real16 getFraction (Real16 rVal)
static Real16 getPortion (Real16 rVal)
static Real16 getFromString (const Char8 *szString)
static std::string putToString (const Real16 val)

Static Public Attributes

static const bool IsPOD = true
static const MathTypeProperties MathProp = RealValue

Detailed Description

template<>
struct osg::TypeTraits< Real16 >

Definition at line 760 of file OSGBaseTypeTraits.h.


Member Typedef Documentation

typedef Real16 osg::TypeTraits< Real16 >::RealReturnType
 

Definition at line 762 of file OSGBaseTypeTraits.h.


Member Function Documentation

static Real16 osg::TypeTraits< Real16 >::getZeroElement void   )  [inline, static]
 

Definition at line 768 of file OSGBaseTypeTraits.h.

00769     {
00770         return Real16( 0.f );
00771     }

static Real16 osg::TypeTraits< Real16 >::getOneElement void   )  [inline, static]
 

Definition at line 773 of file OSGBaseTypeTraits.h.

00774     {
00775         return Real16( 1.f );
00776     }

static Real16 osg::TypeTraits< Real16 >::getMax void   )  [inline, static]
 

Definition at line 778 of file OSGBaseTypeTraits.h.

References REAL16_MAX.

00779     {
00780         return REAL16_MAX;
00781     }

static Real16 osg::TypeTraits< Real16 >::getMin void   )  [inline, static]
 

Definition at line 783 of file OSGBaseTypeTraits.h.

References REAL16_MIN.

00784     {
00785         return REAL16_MIN;
00786     }

static Real16 osg::TypeTraits< Real16 >::getFraction Real16  rVal  )  [inline, static]
 

Definition at line 789 of file OSGBaseTypeTraits.h.

00789 { return rVal; };

static Real16 osg::TypeTraits< Real16 >::getPortion Real16  rVal  )  [inline, static]
 

Definition at line 790 of file OSGBaseTypeTraits.h.

00790 { return rVal; };

static Real16 osg::TypeTraits< Real16 >::getFromString const Char8 szString  )  [inline, static]
 

Definition at line 793 of file OSGBaseTypeTraits.h.

00794     {
00795         if(szString != NULL)
00796         {
00797 #if defined(__sgi) || defined(WIN32)
00798             return Real16(Real32(atof  (szString)));
00799 #else
00800             return Real16(Real32(strtof(szString, NULL)));
00801 #endif
00802         }
00803         else
00804         {
00805             return getZeroElement();
00806         }
00807     }

static std::string osg::TypeTraits< Real16 >::putToString const Real16  val  )  [inline, static]
 

Definition at line 809 of file OSGBaseTypeTraits.h.

00810     {
00811         Char8 buffer[20];
00812 
00813         sprintf(buffer, "%e", (Real32) val);
00814 
00815         return std::string(buffer);
00816     }


Member Data Documentation

const bool osg::TypeTraits< Real16 >::IsPOD = true [static]
 

Definition at line 765 of file OSGBaseTypeTraits.h.

const MathTypeProperties osg::TypeTraits< Real16 >::MathProp = RealValue [static]
 

Definition at line 766 of file OSGBaseTypeTraits.h.


The documentation for this struct was generated from the following file:
Generated on Thu Aug 25 04:12:32 2005 for OpenSG by  doxygen 1.4.3