diff options
author | Ansis Brammanis <brammanis@gmail.com> | 2016-01-15 17:39:08 -0800 |
---|---|---|
committer | Ansis Brammanis <brammanis@gmail.com> | 2016-01-19 18:23:21 -0800 |
commit | d34f8eb674b9753c47616f37ae88ff7a02f61ba0 (patch) | |
tree | c19cfd5ba6b68c229b6e395f9a62294ab33d46f9 /src/mbgl/sprite/sprite_atlas.hpp | |
parent | 26faa6a5ade54c0a423aab84106876dc59be868f (diff) | |
download | qtlocation-mapboxgl-d34f8eb674b9753c47616f37ae88ff7a02f61ba0.tar.gz |
[core][ios][osx][android] make SpriteImage accept PremultipliedImage
the SpriteImage constructor signature changes from
SpriteImage(
uint16_t width, uint16_t height, float pixelRatio,
std::string&& data, bool sdf = false);
to
SpriteImage(PremultipliedImage&&, float pixelRatio, bool sdf = false)
Diffstat (limited to 'src/mbgl/sprite/sprite_atlas.hpp')
-rw-r--r-- | src/mbgl/sprite/sprite_atlas.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/sprite/sprite_atlas.hpp b/src/mbgl/sprite/sprite_atlas.hpp index f577004704..73b3037ec6 100644 --- a/src/mbgl/sprite/sprite_atlas.hpp +++ b/src/mbgl/sprite/sprite_atlas.hpp @@ -32,7 +32,7 @@ struct SpriteAtlasPosition { struct SpriteAtlasElement { Rect<uint16_t> pos; - std::shared_ptr<const SpriteImage> texture; + std::shared_ptr<const SpriteImage> spriteImage; float relativePixelRatio; }; @@ -77,13 +77,13 @@ private: struct Holder : private util::noncopyable { inline Holder(const std::shared_ptr<const SpriteImage>&, const Rect<dimension>&); inline Holder(Holder&&); - std::shared_ptr<const SpriteImage> texture; + std::shared_ptr<const SpriteImage> spriteImage; const Rect<dimension> pos; }; using Key = std::pair<std::string, bool>; - Rect<SpriteAtlas::dimension> allocateImage(float width, float height); + Rect<SpriteAtlas::dimension> allocateImage(const SpriteImage&); void copy(const Holder& holder, const bool wrap); std::recursive_mutex mtx; |