LuciadCPillar 2023.1.04
|
This callback can be used to execute tasks on the render thread right before or right after the Map is painted by Map::Renderer
.
More...
#include <luciad/maps/Map.h>
Public Member Functions | |
virtual | ~IRendererCallback ()=default |
virtual void | onAfterPaint (const std::shared_ptr< Map > &map)=0 |
This method is called after the renderer has finished painting the contents of the Map. More... | |
virtual void | onBeforePaint (const std::shared_ptr< Map > &map)=0 |
This method is called before the renderer paints the contents of the Map. More... | |
Static Public Member Functions | |
static std::shared_ptr< IRendererCallback > | create (std::function< void(const std::shared_ptr< Map > &map)> onBeforePaintFunction, std::function< void(const std::shared_ptr< Map > &map)> onAfterPaintFunction) |
Creates a default IRendererCallback instance that delegates to the given functions. More... | |
This callback can be used to execute tasks on the render thread right before or right after the Map is painted by Map::Renderer
.
This callback can for example be used to adapt the camera on each repaint.
You can add
or remove
this callback from the Map.
|
virtualdefault |
|
static |
Creates a default IRendererCallback instance that delegates to the given functions.
This is a convenience method that allows to reduce boiler plate code, and use lambdas.
onBeforePaintFunction | the function that is called by IRendererCallback::onBeforePaint |
onAfterPaintFunction | the function that is called by IRendererCallback::onAfterPaint |
|
pure virtual |