#include <Cloud2D.h>
Public Member Functions | |
| Cloud2D () | |
| ~Cloud2D () | |
| void | Cloud2D::SetGeometry () |
| void | Cloud2D::SetGeometry (osg::Vec3 position, osg::Vec2 size) |
| void | Cloud2D::Create (osg::Geode *geode, osg::Image *perlinImg) |
| void | Create (osg::Geode *geode, osg::Image *perlinImg, osg::Image *perlinNormalImg) |
| void | Create (osg::Geode *geode, osg::Image *perlinImg, osg::Image *perlinNormalImg, osg::Image *perlinHeightImg) |
| osg::Image * | CreateNormalMap (osg::Image *img) |
| virtual void | SetupGeometry (osg::Vec3 position, osg::Vec2 size, osg::Vec3Array *vertices, osg::Vec2Array *tcoords, osg::UIntArray *indices)=0 |
Public Attributes | |
| osg::Geometry * | geom |
| osg::Geode * | geode |
| osg::Node * | terrain_obj |
| bool | m_tesselation |
Protected Attributes | |
| osg::Vec3Array * | coords |
| osg::Vec2Array * | tcoords |
| osg::UIntArray * | indices |
Parent class to create a 2D cloud Provides methods, which are needed to create a 2D cloud (like normal map creation
| osgCloudyDay::Cloud2D::Cloud2D | ( | void | ) |
Constructor to crate 2D clouds
| osgCloudyDay::Cloud2D::~Cloud2D | ( | void | ) |
Deconstructor
| void osgCloudyDay::Cloud2D::Cloud2D::Create | ( | osg::Geode * | geode, |
| osg::Image * | perlinImg | ||
| ) |
Create the 2D cloud
| geode | geode of the 2D cloud |
| perlinImg | texture of the 2D cloud |
| void osgCloudyDay::Cloud2D::Cloud2D::SetGeometry | ( | ) |
Setup the geometry to render
| void osgCloudyDay::Cloud2D::Cloud2D::SetGeometry | ( | osg::Vec3 | position, |
| osg::Vec2 | size | ||
| ) |
Setup the geometry to render
| position | position of the 2D cloud |
| size | size of the 2D cloud |
| void osgCloudyDay::Cloud2D::Create | ( | osg::Geode * | geode, |
| osg::Image * | perlinImg, | ||
| osg::Image * | perlinNormalImg | ||
| ) |
Create the 2D cloud
| geode | geode of the 2D cloud |
| perlinImg | texture of the 2D cloud |
| perlinNormalImg | normal of the 2D cloud |
| void osgCloudyDay::Cloud2D::Create | ( | osg::Geode * | geode, |
| osg::Image * | perlinImg, | ||
| osg::Image * | perlinNormalImg, | ||
| osg::Image * | perlinHeightImg | ||
| ) |
Create textures
| geode | geode of the 2D cloud |
| perlinImg | texture of the 2D cloud |
| perlinNormalImg | normal of the 2D cloud |
| perlinHeightImg | height texture of the 2D cloud |
| osg::Image * osgCloudyDay::Cloud2D::CreateNormalMap | ( | osg::Image * | img | ) |
Method to creat the Normal map using a Sobel filter
| img | texture |
|
pure virtual |
Creates the geometry to render the 2D cloud
| position | position of the 2D cloud |
| size | size of the 2D cloud |
| vertices | vertices array |
| tcoords | texture coordinates array |
| indices | indices array |
Implemented in osgCloudyDay::PerlinNoiseCloud, osgCloudyDay::CirrusCumulus, osgCloudyDay::Cirrus, osgCloudyDay::CirrusStratus, and osgCloudyDay::AltStratus.
1.8.1.1