osgEarth 2.1.1
|
Public Member Functions | |
CustomTileSource (const TileSourceOptions &options=TileSourceOptions()) | |
void | initialize (const std::string &referenceURI, const Profile *overrideProfile) |
osg::Image * | createImage (const TileKey &key, ProgressCallback *progress) |
Public Attributes | |
osg::ref_ptr< Ring > | _geom |
Definition at line 46 of file osgearth_tilesource.cpp.
CustomTileSource::CustomTileSource | ( | const TileSourceOptions & | options = TileSourceOptions() | ) | [inline] |
Definition at line 49 of file osgearth_tilesource.cpp.
osg::Image* CustomTileSource::createImage | ( | const TileKey & | key, |
ProgressCallback * | progress | ||
) | [inline, virtual] |
Creates an image for the given TileKey. The returned object is new and is the responsibility of the caller.
Implements osgEarth::TileSource.
Definition at line 66 of file osgearth_tilesource.cpp.
{ GeometryRasterizer rasterizer( 256, 256 ); rasterizer.draw( _geom.get(), colors[key.getLevelOfDetail() % 4] ); return rasterizer.finalize(); }
void CustomTileSource::initialize | ( | const std::string & | referenceURI, |
const Profile * | overrideProfile | ||
) | [inline, virtual] |
Initialize the TileSource. The profile should be computed and set here using setProfile()
Implements osgEarth::TileSource.
Definition at line 58 of file osgearth_tilesource.cpp.
{ if ( overrideProfile ) setProfile( overrideProfile ); else setProfile( Registry::instance()->getGlobalGeodeticProfile() ); }
osg::ref_ptr<Ring> CustomTileSource::_geom |
Definition at line 73 of file osgearth_tilesource.cpp.