|
|
| GeoLayer (const std::string &id, int depth) |
| |
|
void | setClippingMargins (int left, int right, int top, int bottom) |
| |
|
void | getClippingMargins (int &left, int &right, int &top, int &bottom) |
| |
|
bool | needsClipping () const |
| |
|
void | beginClipping (const STK::Viewport &glViewport) |
| |
|
void | endClipping () |
| |
|
int | getDepth () const |
| |
|
void | setDepth (int depth) |
| |
|
const std::string & | getId () const |
| |
|
void | setOpacity (float opacity) |
| |
|
float | getOpacity () const |
| |
|
bool | isEnabled () const |
| |
|
void | setEnabled (bool enabled) |
| |
|
void | setNeedsUpdate (bool dirty) |
| | Force update of the layer on next frame. This will also trigger a redraw.
|
| |
|
bool | needsUpdate () const |
| | True if we have requested an update on the next frame. Will reset on next update.
|
| |
|
void | setPerformanceGraph (const std::shared_ptr< STK::PerformanceGraphs::Graph > &perf) |
| |
|
const std::shared_ptr< STK::PerformanceGraphs::Graph > & | getPerformanceGraph () const |
| |
| virtual bool | update (const std::shared_ptr< RasterProjector > &viewport, double scale, float pixelScale, bool sync) |
| | Update layer for rendering. This method should determine if there is anything to render in the layer, and prepare the layer for rendering. This includes for example visibility testing, loading of data, generating graphics structures, etc.
|
| |
|
virtual void | redraw (const std::shared_ptr< RasterProjector > &vp, const STK::Camera &cam, const STK::Viewport &glViewport)=0 |
| |
| virtual void | cleanupCaches (bool keepCurrentFrame) |
| | This method is called at regular intervals to clean up cached data, such as OpenGL textures, graphics buffers etc. Only data that can be reproduced automatically should be cleaned up by this method.
|
| |
| virtual bool | needsRedraw () const |
| | Check if a layer requires a redraw on next frame. This will typically be due to changed content, newly loaded data, etc.
|
| |
GeoLayer - Geographical data layer
| bool Maria::GeoLayer::update |
( |
const std::shared_ptr< RasterProjector > & |
viewport, |
|
|
double |
scale, |
|
|
float |
pixelScale, |
|
|
bool |
sync |
|
) |
| |
|
virtual |
Update layer for rendering. This method should determine if there is anything to render in the layer, and prepare the layer for rendering. This includes for example visibility testing, loading of data, generating graphics structures, etc.
- Parameters
-
| viewport | |
| scale | Map scale for the current view. |
| pixelScale | Scale factor for the pixel allowed pixel size. |
| sync | Synchronous loading of data. This will be true in settings where we need all data to be loaded synchronously, for example when rendering to a bitmap. |
- Returns
- True if the layer should be rendered, false if not.
Reimplemented in Maria::ElevationAnalysisLayer, Maria::GridLayer, Maria::MapLayer, and Maria::RadioNetworksLayer.