Young Hahn
199ea2a82a
Support for icon-text-fit, icon-text-fit-padding ( #5334 )
...
* Add support for icon-text-fit
* Port unit tests for getIconQuads() from js => cpp
* Add support for padding in all 4 directions.
* Update all hashes post-merge
2016-06-15 17:13:31 -04:00
John Firebaugh
a020e535ca
[core] Add a few conveniences to Color
2016-06-15 13:22:00 -07:00
Bruno de Oliveira Abinader
a56f65a4d8
[core] Removed duplicated code in circle shader blur
...
Antialiased blur calculation now happens inside the vertex shader code.
2016-06-15 18:53:05 +03:00
Bruno de Oliveira Abinader
fc0f4edef3
[core] Fix sublayer depth when drawing stroke
...
Port from -js: 002c690712
2016-06-15 18:53:05 +03:00
Bruno de Oliveira Abinader
54e3aa185f
[core] Cleaned up Painter::render{Background,Fill}
2016-06-15 18:53:05 +03:00
Bruno de Oliveira Abinader
814e516a4f
[core] Separate pattern size from draw-time variables
...
Part of https://github.com/mapbox/mapbox-gl-shaders/issues/1 .
2016-06-15 18:53:05 +03:00
Young Hahn
24b66bc8cd
Color class ( #5361 )
...
* Color class
* Switch to list initialization
2016-06-15 11:38:22 -04:00
Bruno de Oliveira Abinader
001b545290
[tidy/linux] modernize-use-default
2016-06-14 22:14:11 +03:00
John Firebaugh
98357ab68e
[core] Add Source::startRender for parallelism with finishRender
2016-06-14 11:25:45 -07:00
Bruno de Oliveira Abinader
7ac7ac13f5
[tidy] Check modernize-use-default
...
Ref: http://clang.llvm.org/extra/clang-tidy/checks/modernize-use-default.html
2016-06-13 23:32:06 +03:00
Bruno de Oliveira Abinader
4161d197fd
[tidy] Check modernize-pass-by-value
...
Ref: http://clang.llvm.org/extra/clang-tidy/checks/modernize-pass-by-value.html
2016-06-13 23:32:05 +03:00
Bruno de Oliveira Abinader
9142c447e8
[tidy] Check llvm-namespace-comment
...
Ref: http://clang.llvm.org/extra/clang-tidy/checks/llvm-namespace-comment.html
2016-06-13 23:32:05 +03:00
John Firebaugh
5c7dfd948f
[core] *Tile ↔ *TileData
...
Tile is now the main base class; RasterTile, VectorTile, etc are its subclasses. GeometryTileData and its subclasses form the piece that's passed to the worker.
2016-06-13 10:59:33 -07:00
John Firebaugh
3ab7c1cca3
[core] Tile ⇢ RenderTile
2016-06-13 10:57:46 -07:00
Bruno de Oliveira Abinader
bfcd21dd7e
[core] Update line-pattern shader code/tests
...
Refs:
- mapbox-gl-test-suite: https://github.com/mapbox/mapbox-gl-test-suite/pull/107
- mapbox-gl-shaders: https://github.com/mapbox/mapbox-gl-shaders/pull/17
- mapbox-gl-js: https://github.com/mapbox/mapbox-gl-js/pull/2724
Part of https://github.com/mapbox/mapbox-gl-shaders/issues/1 .
2016-06-13 13:16:47 +03:00
Konstantin Käfer
2bdecdf9f9
[core] fix pedantic warning messages
2016-06-13 11:16:19 +02:00
Young Hahn
ecd4aa1439
text-pitch-alignment ( #5288 )
...
* First pass at port of https://github.com/mapbox/mapbox-gl-js/pull/2668
* RotationAlignmentType => AlignmentType
* Handle undefined default value for text-pitch-alignment and implement inheritance for this value from text-rotation-alignment
* Update dependencies
* Move handling fo undefined default value out of camelize functions
2016-06-10 23:05:15 -04:00
Bruno de Oliveira Abinader
8b28b6ab6b
[core] Renamed OutlineShader's color uniform
...
Part of https://github.com/mapbox/mapbox-gl-shaders/issues/8 .
2016-06-07 15:04:02 +03:00
Konstantin Käfer
aa88ca4757
[core] remove unused code
2016-06-07 13:55:35 +02:00
Thiago Marcos P. Santos
7b8698b47a
[core] Naive atomic type for ARMv5
...
std::atomic<bool> is implemented lock free which doesn't work
on ARMv5 and seems like the compiler is generating bogus code.
This workaround is a naive implementation using regular mutexes.
2016-06-06 22:19:25 +03:00
John Firebaugh
e1a58565c8
[core] Move RenderData alongside RenderItem
2016-06-02 15:44:39 -07:00
John Firebaugh
c902f9098b
[core] Rationalize naming for style-related code
2016-06-02 14:51:39 -07:00
John Firebaugh
a43940afb2
[core] Runtime style layer API
2016-06-02 14:51:39 -07:00
Bruno de Oliveira Abinader
1b0683b94c
[core] Use unique_resource for GL objects
...
Source: https://github.com/okdshin/unique_resource
These replace the complexity of manually handling moveable-RAII objects
with a type specific for that purpose.
As suggested in https://github.com/mapbox/mapbox-gl-native/pull/5141#issuecomment-221719872 .
2016-06-01 13:53:39 +03:00
Bruno de Oliveira Abinader
2038a21cb5
[core] s/GLObjectStore/ObjectStore/
2016-06-01 13:53:39 +03:00
Bruno de Oliveira Abinader
59f9a9f93c
[core] Update sdf shader code
...
Ported the following patch:
- [convert mat4 exMatrix to a vec2 extrudeScale](a8d549b7a4 )
2016-06-01 11:18:43 +03:00
Bruno de Oliveira Abinader
5e7736ce87
[core] Update icon shader code
...
Ported the following patch:
- [convert mat4 exMatrix to a vec2 extrudeScale](a8d549b7a4 )
2016-06-01 11:18:18 +03:00
Young Hahn
a800d33dd8
[core] Don't earcut more than 500 inner rings
2016-05-31 10:15:18 -07:00
John Firebaugh
faaafb8387
[core] Replace clipper and libtess with earcut.hpp
2016-05-31 10:15:18 -07:00
Bruno de Oliveira Abinader
62b4dd554a
[core] Update circle shader code
...
Ported the following patches:
- [convert mat4 exMatrix to a vec2 extrudeScale](a8d549b7a4 )
- [Enabled data-driven styling for circle-radius](4356e41fa6 )
- [Reduce shader boilerplate, refactor "Bucket"](7d3da8f191 )
2016-05-31 18:02:40 +03:00
Thiago Marcos P. Santos
9db75f1be3
[core] Fill the initial changeTimes with the reference timestamp of the first frame
...
On the Javascript implementation the array is automatically filled with
zeroes which is not the same thing as `TimePoint::min()`. Here we need
to get our own "zero" which is the timestamp of the first frame.
Fixes #5109
2016-05-27 23:30:12 +03:00
Bruno de Oliveira Abinader
c111250fcc
[core] s/operator bool/created()/ in {GL,TexturePool}Holder
...
Prevents confusing usage of GL holder objects.
2016-05-26 19:36:52 +03:00
John Firebaugh
172e645686
[core] Port "combine line-width and line-gap-width in shader"
...
a9559e911b
fcb9bcebae
2016-05-25 21:37:58 -07:00
John Firebaugh
c568a8ad77
[core] Port "separate u_opacity from u_color"
...
0d34125196
1f5afa7db0
2016-05-25 21:37:58 -07:00
John Firebaugh
672eb61079
[core] box_shader ⇢ collision_box_shader
2016-05-25 21:37:22 -07:00
John Firebaugh
30ec1c1fed
[core] Remove unused dot shader
2016-05-25 21:37:22 -07:00
Konstantin Käfer
b4de5f472a
[core] rename TileData::State to DataAvailability and make it private
2016-05-25 21:51:25 +02:00
Konstantin Käfer
e2bcea90fc
[core] use #pragma once instead of ifdef include guards
2016-05-25 21:35:37 +02:00
Bruno de Oliveira Abinader
1769e6fcb4
[core] Move GLFW stencil clip debug to core
...
This makes the stencil clip debug available to all platforms.
Fixes #4669 .
2016-05-24 19:58:24 +03:00
Konstantin Käfer
b9f23661f8
[core] move RenderItem and GlyphRange to their own headers
2016-05-23 18:04:31 +02:00
Thiago Marcos P. Santos
7b4f5b86af
[core] Restore default texture unit
...
Play nice with the GL context when we are sharing it.
2016-05-23 18:50:34 +03:00
Bruno de Oliveira Abinader
7143408f69
[core] Implement MapDebugOptions::Wireframe
...
Together with MapDebugOptions::Collision, provides "wireframe" rendering
output so all drawn objects are visible. This mode ignores the line
width, background and fill colors for better visualization.
Fixes #4359 .
2016-05-23 11:50:05 +03:00
Ansis Brammanis
4c62a5508c
[core] better symbol fading with texture lookups ( #4579 )
...
- this is simpler than predicting opacity based on current zooming speed
- this is smoother: symbols don't flicker when changing zoom speed or
when zooming in and out rapidly.
1df1466270
fix #4562
2016-05-20 12:19:56 -07:00
Konstantin Käfer
cd65a43855
[core] move from microsecond precision timestamp to integer second precision
2016-05-13 17:24:22 +02:00
John Firebaugh
1a030e7c33
[core] Normalize tile coordinates in VectorTile ( #4966 )
...
Previously, vector tile coordinates were being normalized to util::EXTENT in each place they were used, and for annotation and GeoJSON sources that don't require normalization.
2016-05-11 13:54:05 -07:00
Bruno de Oliveira Abinader
c13dd32242
[core] Added Viewport mode
...
Satisfies embedding platforms that requires the viewport coordinate
systems to be set according to its standards e.g. viewport mirrored
vertically.
2016-05-11 15:48:51 +03:00
Konstantin Käfer
7332ae0073
[core] retain tiles differently and remove old TileID class
2016-05-10 14:50:56 +02:00
Konstantin Käfer
ec70125e41
[core] move TileData and dependents to new *TileID classes
2016-05-10 14:50:56 +02:00
Konstantin Käfer
bdcbceff80
[core] move Tile to use UnwrappedTileID
2016-05-10 14:50:56 +02:00
Konstantin Käfer
dde59eaf76
[core] move Painter and dependents to new *TileID classes
2016-05-10 14:50:56 +02:00