Robotsystem of the Robot Group Leipzig: OSGHeightField Class Reference

- Main Page
- Namespaces
- Classes
- Files
- Directories
- Examples

- Search for |

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# OSGHeightField Class Reference

Graphical HeightField. More...

`#include <osgheightfield.h>`

Inherits OSGPrimitive.

Inheritance diagram for OSGHeightField:

[legend]
Collaboration diagram for OSGHeightField:

[legend]
List of all members.

## Public Types
| Red
| Sum
| LowMidHigh
enum | CodingMode { Red, Sum, LowMidHigh }
| height coding using in the read in bitmap. More...
## Public Member Functions
| OSGHeightField (osg::HeightField *heightfield, float x_size, float y_size)
| OSGHeightField (const std::string &filename, float x_size, float y_size, float height)
virtual void | setMatrix (const osg::Matrix &matrix)
| Sets the transformation matrix of this object (position and orientation).
virtual void | init (const OsgHandle &osgHandle, Quality quality=Middle)
virtual const osg::HeightField * | getHeightField () const
## Static Public Member Functions
static osg::HeightField * | loadFromPPM (const std::string &filename, double height, CodingMode codingMode=Red)
| loads an ppm image and returns the height field using the given coding and the height (maximal height of the heightfield)
static double | coding (CodingMode mode, const unsigned char *data)
| return the height using the given coding mode. The data pointer points to RGB data point
## Protected Attributes
osg::HeightField * | field
float | x_size
float | y_size

## Detailed Description

Graphical HeightField.

## Member Enumeration Documentation

enum CodingMode

height coding using in the read in bitmap.

Enumerator:

  Red |
  Sum |
  LowMidHigh |

## Constructor & Destructor Documentation

OSGHeightField | ( | osg::HeightField * | heightfield,
|  | float | x_size,
|  | float | y_size |
| ) |  |  |

OSGHeightField | ( | const std::string & | filename,
|  | float | x_size,
|  | float | y_size,
|  | float | height |
| ) |  |  |

## Member Function Documentation

double coding | ( | CodingMode | mode,
|  | const unsigned char * | data |
| ) |  |  | `[static]`

return the height using the given coding mode. The data pointer points to RGB data point

virtual const osg::HeightField* getHeightField | ( |  | ) | const`[inline, virtual]`

void init | ( | const OsgHandle & | osgHandle,
|  | Quality | quality = `Middle` |
| ) |  |  | `[virtual]`

HeightField * loadFromPPM | ( | const std::string & | filename,
|  | double | height,
|  | CodingMode | codingMode = `Red` |
| ) |  |  | `[static]`

loads an ppm image and returns the height field using the given coding and the height (maximal height of the heightfield)

void setMatrix | ( | const osg::Matrix & | matrix | ) | `[virtual]`

Sets the transformation matrix of this object (position and orientation).

Reimplemented from OSGPrimitive.

## Member Data Documentation

osg::HeightField* field`[protected]`

float x_size`[protected]`

float y_size`[protected]`

The documentation for this class was generated from the following files:

- osgheightfield.h
- osgheightfield.cpp