diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2015-04-16 10:34:30 +0200 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2015-04-17 13:40:42 +0200 |
commit | 46bf2269107b21d20fc84ef46a9ce5c2bfeea519 (patch) | |
tree | 5afa856c246a8c99db7cfeab55adcdc59ca50a9f /include/mbgl/map/still_image.hpp | |
parent | cd496645d435a192af3060f06fbe9f2baca76d1a (diff) | |
download | qtlocation-mapboxgl-46bf2269107b21d20fc84ef46a9ce5c2bfeea519.tar.gz |
align static render mode and still image render mode
- static rendering now also runs in a separate thread; you have to start it with map.start(Map::Mode::Static) and join the thread with map.stop() before destructing the Map object
- map.renderStill() takes a callback with will be invoked on the *map* thread, so you'll have to figure out your own method of dispatching back to the main thread.
Diffstat (limited to 'include/mbgl/map/still_image.hpp')
-rw-r--r-- | include/mbgl/map/still_image.hpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/include/mbgl/map/still_image.hpp b/include/mbgl/map/still_image.hpp new file mode 100644 index 0000000000..b9ce0620fa --- /dev/null +++ b/include/mbgl/map/still_image.hpp @@ -0,0 +1,21 @@ +#ifndef MBGL_MAP_STILL_IMAGE +#define MBGL_MAP_STILL_IMAGE + +#include <mbgl/util/noncopyable.hpp> + +#include <string> +#include <cstdint> + +namespace mbgl { + +class StillImage : util::noncopyable { +public: + uint16_t width = 0; + uint16_t height = 0; + using Pixel = uint32_t; + std::unique_ptr<Pixel[]> pixels; +}; + +} + +#endif |