Commit Graph

210 Commits

Author SHA1 Message Date
Justin R. Miller
bd0bf294bf squash of #1655: shape annotations support for core & iOS 2015-06-15 18:30:39 -07:00
Minh Nguyễn
714b68f7b3 Revert "use array of structs rather than parallel arrays for annotations"
This reverts commit 2435c1ad26 (#1710), which needs to be revisited in light of #1655, which is a much higher priority at the moment.
2015-06-15 15:58:22 -07:00
Konstantin Käfer
2435c1ad26 use array of structs rather than parallel arrays for annotations 2015-06-11 17:26:37 -04:00
Ansis Brammanis
ff6a5ce5bc Merge remote-tracking branch 'origin/master' into new-labelling
Conflicts:
	src/mbgl/map/source.cpp
	src/mbgl/map/source.hpp
	src/mbgl/map/tile_data.cpp
	src/mbgl/map/tile_parser.cpp
	src/mbgl/map/vector_tile_data.cpp
	src/mbgl/renderer/painter.cpp
	src/mbgl/renderer/symbol_bucket.cpp
	src/mbgl/text/glyph.hpp
	src/mbgl/text/glyph_store.cpp
	src/mbgl/text/placement.cpp
	test/suite
2015-05-28 20:01:15 -04:00
Ansis Brammanis
8962442b1b make collision debug boxes toggleable 2015-05-28 19:17:07 -04:00
John Firebaugh
87b1da7611 DefaultFileSource has responsibility for handling mapbox:// URLs 2015-05-26 12:14:10 +02:00
Thiago Marcos P. Santos
da81211fea Add callback for error notifications on renderStill()
The callback will be called when any of the resources requested
from the network failed to load.

There is not recovery implemented yet, so the closest thing to
reseting the Map object and reloading all the resources would
be setting a new style.
2015-05-22 10:44:18 +03:00
John Firebaugh
386be7c0fa Remove unused
There are no longer any requests made that don't have a run loop to
dispatch back to.
2015-05-13 13:54:16 -07:00
Leith Bade
703e0bc2ee Ignore deactivate when no valid EGL display. Fixes #1435
Initialise NativeMapView's EGL variables before Map

Fix hang

Add check for double pause

Add test for double pause
2015-05-09 12:02:39 +10:00
Konstantin Käfer
691c305467 add Map::isFullyLoaded()
returns whether the Map is still loading/parsing any assets or whether everything is there and a render will likely be complete
2015-05-05 11:47:23 +02:00
John Firebaugh
00a1f44cfc Ensure no GL commands are executed after pause 2015-05-04 18:27:48 -07:00
John Firebaugh
8bb7fc64ff Move Environment to MapContext 2015-04-28 14:32:25 -04:00
John Firebaugh
3bf0bf9538 Remove unused includes 2015-04-28 14:32:25 -04:00
John Firebaugh
f8db45f19a Move still image callback to MapContext 2015-04-28 14:32:25 -04:00
John Firebaugh
f0b229730f Move style info to MapContext 2015-04-28 14:32:25 -04:00
John Firebaugh
b5b58086a8 Combine update and triggerUpdate 2015-04-28 14:32:25 -04:00
John Firebaugh
230027e514 Resize view from map thread 2015-04-28 14:32:24 -04:00
John Firebaugh
a625ba8a09 Remove Map::start/stop
Both Android and iOS now use pause/resume. The map thread is
always running, and be able to receive messages. When paused,
it will just refuse to render.
2015-04-28 14:32:24 -04:00
John Firebaugh
6c7a01a503 Following kkaefer's view changes 2015-04-28 14:32:22 -04:00
John Firebaugh
75ae956b0e WIP: Use Thread<MapContext> 2015-04-28 14:32:22 -04:00
John Firebaugh
025eb013d7 Privatize remaining MapContext members 2015-04-28 14:32:21 -04:00
John Firebaugh
424dae0a2c Move run() to MapContext 2015-04-28 14:32:21 -04:00
John Firebaugh
d67f862400 #include <atomic> 2015-04-28 14:32:21 -04:00
Konstantin Käfer
dae18cc7bc remove some unused includes 2015-04-28 14:32:21 -04:00
Konstantin Käfer
b0a30943b4 move most private Map code to MapContext 2015-04-28 14:32:20 -04:00
Konstantin Käfer
9dc51e7f80 move rendering mode enum to MapData object 2015-04-28 14:32:20 -04:00
Konstantin Käfer
fa272b3aaa move asyncRender to MapContext 2015-04-28 14:32:20 -04:00
Konstantin Käfer
f8600d8d97 move getSprite to MapContext 2015-04-28 14:32:20 -04:00
Konstantin Käfer
9580ec7b08 move Style to MapContext 2015-04-28 14:32:20 -04:00
Konstantin Käfer
f272d13dea move worker to MapContext 2015-04-28 14:32:19 -04:00
Konstantin Käfer
849febbfc4 remove unneeded headers 2015-04-28 14:32:19 -04:00
Konstantin Käfer
07525d5d50 move Sprite to MapContext 2015-04-28 14:32:19 -04:00
Konstantin Käfer
9af7af3109 move GlyphStore to MapContext 2015-04-28 14:32:19 -04:00
Konstantin Käfer
63acd5b0a1 move texturepool to context 2015-04-28 14:32:19 -04:00
Konstantin Käfer
9b64edd712 remove unused reference 2015-04-28 14:32:18 -04:00
Konstantin Käfer
ad0178fd45 move atlas/painter to map context 2015-04-28 14:32:18 -04:00
Konstantin Käfer
7c8c45edab move activeSources to internal Map context 2015-04-28 14:32:18 -04:00
Konstantin Käfer
89167cbf8c move Transform into MapData and make source unaware of the Map object 2015-04-28 14:32:18 -04:00
Konstantin Käfer
cc8f440c84 move TransformState to MapData object 2015-04-28 14:32:17 -04:00
John Firebaugh
c0b75f1af7 Remove Environment::terminate and associated code
Fixes #1336
2015-04-28 09:16:26 -04:00
Konstantin Käfer
71d127220b rename Mode::Static => Mode::Still 2015-04-17 17:55:24 +02:00
Konstantin Käfer
46bf226910 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.
2015-04-17 13:40:42 +02:00
Justin R. Miller
190709c6b1 fixes #1157, #1255: cache parsed tiles in memory 2015-04-16 01:15:41 -07:00
Mike Morris
5972a7d16e make environment.hpp header public 2015-04-15 17:14:36 +02:00
John Firebaugh
6708959d12 Remove some uv.hpp includes 2015-04-09 15:30:58 -07:00
John Firebaugh
0c087603e6 Replace uv_messenger with AsyncQueue; rewrite remaining uv_* in C++ 2015-04-09 15:30:58 -07:00
John Firebaugh
d8411f26d2 Tile::ID ⇢ TileID
This allows making both Tile and TileID private.
2015-04-06 13:58:56 -07:00
John Firebaugh
7e0e55e542 Eliminate StyleSource
Fixes #695
2015-04-06 10:30:01 -07:00
Minh Nguyễn
6a1e7d5707 Fixed race condition after setting access token
`Map` should be able to deal with having no access token or JSON even while it’s running. Most of `Map` accounts for this situation, but `reloadStyle()` incorrectly assumes that one or the other is set. This change corrects the assumption in `reloadStyle()`.

Also expose the access token and style name to clients as ordinary KVO-compliant properties. Actually, they’re not so ordinary because they’re inspectable!

Ref #1070, #1147
2015-04-03 12:07:53 -07:00
John Firebaugh
12c07b916b Rework easing transition code
This brings the easing transition code a bit closer to how easings work
in gl-js. Instead of having an array of individual transitions for scale,
rotate, and pan, there is a single transition function that does all the
required calculations. This permits us to:

* Eliminate the "timeout" transition. (Fixes #126)
* Replace start/stopPanning() et al with setGestureInProgress(). Apps or
  SDKs are expected to make paired calls to setGestureInProgress(). This
  state will be ORed with the active easing state to determine when to
  use texture interpolation. (Fixes #79)
* Run style recalculations only when an ease transition that affects the
  zoom is in progress. (Fixes #1155)
2015-04-02 16:12:29 -07:00