|
LuciadCPillar 2026.1.02
|
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, Renderer &mapRenderer)=0 |
This method is called after the renderer has finished painting the contents of the Map. | |
| virtual void | onBeforePaint (const std::shared_ptr< Map > &map, Renderer &mapRenderer)=0 |
This method is called before the renderer paints the contents of the Map. | |
Static Public Member Functions | |
| static std::shared_ptr< IRendererCallback > | create (std::function< void(const std::shared_ptr< Map > &map, Renderer &mapRenderer)> onBeforePaintFunction, std::function< void(const std::shared_ptr< Map > &map, Renderer &mapRenderer)> onAfterPaintFunction) |
| Creates a default IRendererCallback instance that delegates to the given functions. | |
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 |