Commit Graph

4631 Commits

Author SHA1 Message Date
Konstantin Käfer
c66ec8739b show info message when Sprite does not exist 2015-07-08 19:46:03 +02:00
Konstantin Käfer
493c72b1f4 move crc64() to test fixture 2015-07-08 19:46:03 +02:00
Konstantin Käfer
74b744a656 test SpriteAtlas updates when SpriteStore was updated 2015-07-08 19:46:03 +02:00
Konstantin Käfer
0d4cfd5bd6 test for sprite image that doesn't exist 2015-07-08 19:46:02 +02:00
Konstantin Käfer
d37bd549bc make sure that the SpriteStore object correctly replaces the SpriteImages 2015-07-08 19:46:02 +02:00
Konstantin Käfer
32699333e6 add image to odd pixelRatio atlas 2015-07-08 19:46:02 +02:00
Konstantin Käfer
d08ec53a0e add test for fractional pixel ratios 2015-07-08 19:46:02 +02:00
Konstantin Käfer
a57f3ddceb add basic SpriteAtlas test 2015-07-08 19:46:02 +02:00
Konstantin Käfer
c5ed00ae7a fix sprite debug window code 2015-07-08 19:46:02 +02:00
Konstantin Käfer
746e4d20ee explicitly name the sprite that couldn't be changed 2015-07-08 19:46:02 +02:00
Konstantin Käfer
62ac43a85b add ability to add random custom markers to test app 2015-07-08 19:46:02 +02:00
Konstantin Käfer
b2a3314192 replace Style object immediately
this makes sure that adding custom sprite imagery will add them to the new Style object rather than
the old one in case a user adds new custom sprites immediately after changing a stylesheet
2015-07-08 19:46:01 +02:00
Konstantin Käfer
f9601ae685 add ability to set custom sprites on the Map object 2015-07-08 19:46:01 +02:00
Konstantin Käfer
70d0a26f98 key sprites in sprite atlas by name and wrap value 2015-07-08 19:46:01 +02:00
Konstantin Käfer
a0e391c0cb make sure that Sprite isn't marked as loaded until we actually added everything to the SpriteStore 2015-07-08 19:46:01 +02:00
Konstantin Käfer
6271f8e546 mark Image constructor as explicit to avoid accidental implicit argument conversion
when passing a std::string instead of an Image, the parameter gets implicitly and automatically converted (== parsed) to a temporary Image object. Since parsing an Image shouldn't be a frequent operation
2015-07-08 19:46:01 +02:00
Konstantin Käfer
bc41d3cf6d don't restrict pixelRatio in SpriteStore
this is required so that devices that aren't using 1x or 2x (like the iPhone 6 Plus with a pixelRatio of 3x) still show icons, albeit bilinearly scaled to the correct size in the SpriteAtlas
2015-07-08 19:46:01 +02:00
Konstantin Käfer
4f48874ef0 we're no longer throwing exceptions when loading invalid sprite resources 2015-07-08 19:46:01 +02:00
Konstantin Käfer
afaf74e41a use SpriteStore from the SpriteAtlas 2015-07-08 19:46:00 +02:00
Konstantin Käfer
d2ee014c6e move SpriteAtlas to the SpriteStore backend 2015-07-08 19:46:00 +02:00
Konstantin Käfer
aa2dcf1968 disallow changing an existing Sprite's size 2015-07-08 19:46:00 +02:00
Konstantin Käfer
086e72afe3 use a 64 bit CRC value instead of std::hash 2015-07-08 19:46:00 +02:00
Konstantin Käfer
d880507f84 add missing headers 2015-07-08 19:46:00 +02:00
Konstantin Käfer
33a3388ccd add API for adding multiple sprites at once 2015-07-08 19:46:00 +02:00
Konstantin Käfer
54aaa43b6d add test for trying to add mismatched SpriteImage 2015-07-08 19:46:00 +02:00
Konstantin Käfer
04d57b8ef2 check for presence of Sprite creation warnings 2015-07-08 19:45:59 +02:00
Konstantin Käfer
a96a8fef76 add a separate SpriteParser object
transforms a JSON and an associated PNG file into individual SpriteImage objects that can be inserted into a SpriteStore
2015-07-08 19:45:59 +02:00
Konstantin Käfer
a68b47b969 ratio => pixelRatio 2015-07-08 19:45:59 +02:00
Konstantin Käfer
55ef14f3a8 compress_png: void* => const void* 2015-07-08 19:45:59 +02:00
Konstantin Käfer
9991f9da54 add RAII-style FixtureLog 2015-07-08 19:45:59 +02:00
Konstantin Käfer
7f705da564 Sprite store API 2015-07-08 19:45:59 +02:00
Ansis Brammanis
03c4ed75a2 increase simplification for line annotations
to make them look better when drawn semi-transparently
2015-07-08 16:16:51 +02:00
Ansis Brammanis
888ae5ebdc improve round line joins for semi-transparent lines
https://github.com/mapbox/mapbox-gl-js/pull/1359

Round line joins used to be drawn by adding a semicircle cap to the end
of each segment. This looked fine for opaque lines not for
semi-transparent lines.

This changes the triangulation so that round line joins don't overlap
with segments. The gap between segments is filled with small triangles
that look like pie slices. The edge of the round linejoin is made up of
many short straight lines that look round at the sizes we draw lines.

Since sharp angles are infrequent, this does not significantly affect
the total number of triangles created.

Joins for angles that are really sharp are still drawn with overlap.
2015-07-08 16:16:51 +02:00
Konstantin Käfer
675ddddee7 Make pixelRatio constant across a Map object lifetime
also moves framebuffer size out of TransformState into its own object
2015-07-08 10:40:05 +02:00
Justin R. Miller
3a07cb2f1e [publish ios-v0.4.5] 2015-07-07 21:08:09 -07:00
Justin R. Miller
683556b655 bump podspec to 0.4.5 2015-07-07 21:07:49 -07:00
Minh Nguyễn
88c8ec4601 mapbox/mapbox-gl-styles@6b0f8a9b10 2015-07-07 18:29:56 -07:00
Justin R. Miller
c83d3b3101 Merge pull request #1843 from mapbox/1ec5-lasik-963
Enhance!
2015-07-07 15:33:41 -07:00
Minh Nguyễn
4c1f325bf6 Moved raster zoom threshold to the .5’s
Fixes #963.
2015-07-07 12:14:26 -07:00
Minh Nguyễn
08acb65b1c Eliminated map overrotation on drift pan
Wrap the angle on each interpolated step instead of when normalizing.
2015-07-06 13:08:59 -07:00
Minh Nguyễn
a22efd4e80 Fixed compass overspinning
Rely on mbgl to drive compass rotation for simplicity. Eliminated fall-through from mbgl::MapChangeRegionIsChanging to mbgl::MapChangeRegionDidChange, because is-changing should not cause did-change to be fired.
2015-07-06 13:08:50 -07:00
Minh Nguyễn
46a6173bd7 [wrap)
If (wrap] is desired, it is the responsibility of the caller to handle the case in which min is returned.
2015-07-06 13:07:34 -07:00
Minh Nguyễn
78126f3b6b Refactored -[MGLMapView direction]
Fixed a bug in which -[MGLMapView direction] could return 360 instead of 0. Switched to mbgl::util::wrap() for clarity. -updateCompass now relies on -direction to avoid code duplication.
2015-07-06 13:07:34 -07:00
Konstantin Käfer
3ea640e6e3 run the Assert.Always test first by reordering the symbols 2015-07-06 16:44:48 +02:00
Thiago Marcos P. Santos
ec1b4c43fd Do not force uv_loop_t as the first parameter for a threaded object ctor 2015-07-06 16:01:59 +03:00
Thiago Marcos P. Santos
f6b8dd4be9 Add simple static method to retrieve the current loop
In the lines of how we do for getting information of the
current thread.
2015-07-06 15:54:51 +03:00
Bruno de Oliveira Abinader
106312c0b8 Merge pull request #1836 from mapbox/ycm-osx
Update YCM to support OSX
2015-07-06 15:21:54 +03:00
Bruno de Oliveira Abinader
c15c26eb3d Update YCM to support OSX
Besides a couple file path modifiers, we need to manually add the OSX SDK system root path.
2015-07-05 16:28:58 +03:00
Minh Nguyễn
ec93fba84a Fixed crash on launch on iOS 7
In #1793, I conflated the compass container’s constraints to its parent view with the compass container’s content size constraints, but only in the iOS 7 code path. The result was a crash on launch due to an unprepared view hierarchy.

Fixes #1818.
2015-07-05 01:35:04 -07:00
Bruno de Oliveira Abinader
d8af7319b4 Fixed test run script
- If we cannot find 'gdb' on the system (eg. OSX does not come with gdb
  by default), just run the command for now;
- We were missing passing the whole list of parameters, so I've replaced
  $1 with $@ and added '--args' for gdb to forward the params to the
  program call;
2015-07-03 13:49:38 +03:00