diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2017-05-16 15:53:59 -0700 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2017-05-17 11:23:47 -0700 |
commit | e7154adac3985b8d877c40d16c7d4b3916c7246b (patch) | |
tree | d68c579d078488b5ace871eb8d540d5c6f630de4 /src/mbgl/text/shaping.cpp | |
parent | 786707649a2efcddd24fb976150b044097d74219 (diff) | |
download | qtlocation-mapboxgl-e7154adac3985b8d877c40d16c7d4b3916c7246b.tar.gz |
[core] Remove redundant SpriteAtlasElement members
Diffstat (limited to 'src/mbgl/text/shaping.cpp')
-rw-r--r-- | src/mbgl/text/shaping.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mbgl/text/shaping.cpp b/src/mbgl/text/shaping.cpp index 78aa142c61..5c99a49133 100644 --- a/src/mbgl/text/shaping.cpp +++ b/src/mbgl/text/shaping.cpp @@ -17,10 +17,10 @@ optional<PositionedIcon> PositionedIcon::shapeIcon(const SpriteAtlasElement& ima float dx = iconOffset[0]; float dy = iconOffset[1]; - float x1 = dx - image.width/ 2.0f; - float x2 = x1 + image.width; - float y1 = dy - image.height / 2.0f; - float y2 = y1 + image.height; + float x1 = dx - image.size[0] / 2.0f; + float x2 = x1 + image.size[0]; + float y1 = dy - image.size[1] / 2.0f; + float y2 = y1 + image.size[1]; return { PositionedIcon { image, y1, y2, x1, x2, iconRotation } }; } |