Konstantin Käfer
e0381a782c
use smallest/largest value in undefined regions
...
refs #217
2014-05-20 11:52:17 +02:00
Konstantin Käfer
6bffa49309
don't account for tile size in the function; the value is tile source dependent
2014-05-20 11:51:49 +02:00
Konstantin Käfer
3be068f8da
make sure they never throw. asserts are compiled out in production!
2014-05-20 11:23:33 +02:00
Konstantin Käfer
a6cb3d8402
fix label display
...
refs #217
2014-05-20 11:10:27 +02:00
Ansis Brammanis
2b348ccfd4
Merge branch 'master' of github.com:mapbox/llmr-native
2014-05-19 17:36:50 -04:00
Ansis Brammanis
4d38e4eb15
fix rotation range check in text shader
...
fixes #215
2014-05-19 17:35:55 -04:00
Konstantin Käfer
a33d334169
incorporate the color and draw circle dots if we don't have an icon
...
Conflicts:
bin/style.js
2014-05-19 16:20:51 +02:00
Konstantin Käfer
ee82986717
disable debug image
2014-05-19 14:21:57 +02:00
Konstantin Käfer
92706445d9
init glfw for debug images + actually copy images over
2014-05-19 14:21:15 +02:00
Konstantin Käfer
f848868c16
fix texture binding
2014-05-19 14:18:29 +02:00
Konstantin Käfer
898c6d6714
fix for retina screens
2014-05-19 11:13:22 +02:00
Konstantin Käfer
13575330f7
use sprite atlas
2014-05-19 10:48:36 +02:00
Konstantin Käfer
27f8ed29e4
encode icon texture coordinate in buffer so we can render all pois with 1 draw call
2014-05-19 10:48:36 +02:00
Ansis Brammanis
264bcd34d9
flush command buffers when done
2014-05-16 14:04:12 -04:00
Konstantin Käfer
01183a0a19
fix remaining cases of point => icon
2014-05-15 18:09:00 +02:00
Konstantin Käfer
4c99014a13
don't use fractional texture coordiantes in the shader
2014-05-15 15:16:34 +02:00
Konstantin Käfer
27b695b068
use explicit constructors
2014-05-15 14:56:06 +02:00
Konstantin Käfer
44f8c80d21
also clear text and raster styles
2014-05-15 14:51:11 +02:00
Konstantin Käfer
fda64b67af
rename point => icon
2014-05-15 14:51:02 +02:00
Konstantin Käfer
aeae6248ad
simplify point shader in preparation for #196
2014-05-15 14:27:49 +02:00
Konstantin Käfer
a9d559fe51
return refs to avoid matrix allocation/deallocation for untranslated layers
...
refs #189
2014-05-14 17:21:51 +02:00
Konstantin Käfer
a27f8798ff
add translate-anchor: viewport to lines + points
...
refs #189
2014-05-14 17:17:47 +02:00
Konstantin Käfer
afc54b7956
add translate-anchor for fills
2014-05-14 16:51:27 +02:00
Konstantin Käfer
b167a79c22
always use std:: namespace for math functions
...
fixes #201
2014-05-14 16:40:24 +02:00
Konstantin Käfer
24617da3ff
don't factor in the pixelratio to achieve the same look
...
refs #189
2014-05-14 15:06:31 +02:00
Konstantin Käfer
a812f37c60
make sure to premultiply the colors during stylesheet parsing
...
fixes #193
2014-05-14 15:05:59 +02:00
Konstantin Käfer
3514538719
make text layers respect the translate-anchor
...
you can now specify "translate-anchor": "viewport" to have the text translated
in screen coordinates rather than relative to the tile. The default value
remains "translate-anchor": "map"
refs #189
2014-05-14 10:31:57 +02:00
Konstantin Käfer
32b21b050f
do not define variables until they're needed
2014-05-14 10:31:57 +02:00
Konstantin Käfer
d97e8899ae
add translate-anchor property
2014-05-14 10:31:57 +02:00
Konstantin Käfer
05a330f347
make translate property zoom independent
...
if you want a zoom-dependent translation, you can use a function
refs #189
2014-05-14 10:31:57 +02:00
Justin R. Miller
3a7914261e
fix erroneous abort of raster rendering
2014-05-13 12:28:54 -07:00
Konstantin Käfer
7bfcde4025
split up painter into multiple files
2014-05-13 15:37:45 +02:00
Konstantin Käfer
b096373b71
abort rendering early if the style is disabled
...
refs #184
2014-05-13 15:15:54 +02:00
Konstantin Käfer
ab71db336c
move tiles to std::map for faster lookups
2014-05-13 12:20:59 +02:00
Konstantin Käfer
d8fa9aa322
move weak_ptr list of tile_data objects to a map for faster lookups
2014-05-13 12:01:29 +02:00
Konstantin Käfer
263c887777
don't try to render layers that do not produce anyting during the current render pass
...
refs #184
2014-05-12 19:53:06 +02:00
Konstantin Käfer
2b14579986
only paint layer if it has data
...
refs #184
2014-05-12 19:08:59 +02:00
Konstantin Käfer
d9d9b281c4
disable texture deleting for now
2014-05-12 18:25:58 +02:00
Konstantin Käfer
6ebb4c21f7
clean up gl::group() structure
2014-05-12 18:25:48 +02:00
Konstantin Käfer
6136ab6d21
draw by layer, not by tile
...
This is needed for correctly compositing raster imagery into the map
fixes #122
fixes #157
2014-05-12 17:13:26 +02:00
Konstantin Käfer
0bfd7b0f43
Calculate clip IDs with a huffman prefix tree
...
This changes the clip IDs from sequential to a huffman prefix tree, meaning that
parent tiles share the same prefix with child tiles (but are shorter). This allows
us to use the same checkerboard pattern to draw all tiles.
TODO:
- make sure we're not overflowing the 8 bit limit of the stencil buffer
- draw all checkerboard fields at the same time, with one draw call
- fix raster drawing (fading, clipping)
refs #132
2014-05-09 18:10:28 +02:00
Konstantin Käfer
ee55798842
remove debug code and use unary visitor directly
2014-05-08 13:44:31 +02:00
Konstantin Käfer
7f4f327166
make sure we're not converting too relaxedly
2014-05-08 13:42:54 +02:00
Justin R. Miller
2b9fbb0731
squashed stylequest merge
...
* uses OSM Bright style
* adds dot shader
* adds layer translation
* adds dashed line support
* adds style array parsing
* improves background layer parsing
* improves style constant parsing
* fixes sprite JSON pixel ratio parsing
2014-05-07 10:37:25 -07:00
Konstantin Käfer
93e0c49faa
add variant test
2014-05-02 13:41:45 +02:00
Justin R. Miller
7010954229
refs #159 : fix bug with filtering on numeric layer values
2014-05-02 11:18:59 +02:00
Konstantin Käfer
6574f0d188
add setAngle() call with duration
2014-05-02 10:28:47 +02:00
Konstantin Käfer
485a9a40bc
formatting
2014-05-02 10:25:58 +02:00
Konstantin Käfer
4ac34b49a0
there's no need to reset the image data
2014-05-02 10:25:58 +02:00
Justin R. Miller
e56a8113e7
fix animation duration casting errors
2014-05-01 12:20:39 -07:00