Commit Graph

209 Commits

Author SHA1 Message Date
John Firebaugh
65c28deefe [core] Update gl-js for shader change 2016-12-23 10:49:51 -08:00
John Firebaugh
317b2bf42f [build] Use a submodule for mapbox-gl-js rather than an npm dependency 2016-12-22 15:41:10 -08:00
Ansis Brammanis
29099399a9 [core] clearer pitched line antialiasing
ported from -js: ef5582dd3bc5c15a3112e875ed66494dab8e9d0b

Project the extrusion and compare it's projected pixel length with the
actual pixel length and adjust antialiasing accordingly.

The previous approach calculated the adjustment much more indirectly and
had no intuitive explanation.
2016-12-21 15:46:36 -08:00
Ansis Brammanis
38b5cb0c77 [core, ios] replace altitude with fov
ported from -js: eb6c6596c6a7a61363d30356674e0002153b1d19

`altitude` was a terribly-named variable that was used to indirectly
control the fov. This should eliminate some confusion.

`altitude` was equivalent to `cameraToCenterDistance / height`
2016-12-21 15:46:36 -08:00
Ansis Brammanis
ebd241363d [core] fix text blurriness at different FOVs
ported from -js: c52a09639ceeeb809cd837360993df9c45b45420

This replaces a hardcoded shader approximation with a more correct,
FOV-dependent one.

`gl_Position.w - 0.5`
is replaced with
`gl_Position.w / tan(fov)`

The `/ tan(fov)` is handled by multiplying `1 / tan(fov)` into `u_gamma`
outside the shader.

I think `- 0.5` was just chosen as something that looked right for the
default fov.lease enter the commit message for your changes. Lines starting
2016-12-21 15:46:36 -08:00
John Firebaugh
bcf2c3ff9e [core] Polylabel-based "pole of inaccessibility" symbol placement 2016-12-21 13:42:30 -08:00
John Firebaugh
dad57df38e [core] Fix symbol rendering for multipoints
Ports https://github.com/mapbox/mapbox-gl-js/pull/3763 and https://github.com/mapbox/mapbox-gl-js/pull/3806.
2016-12-20 08:30:39 -08:00
John Firebaugh
f74de67315 [core] Mark tile as incomplete while redoing placement 2016-12-14 12:15:29 -08:00
John Firebaugh
e8a48a6d63 [node] Fix order of operations when setting zoom and center
Zoom must be set first, to avoid center potentially getting constrained.

Fixes #7351
2016-12-14 10:08:23 -08:00
John Firebaugh
ceeded2932 [core] Obtain shaders from gl-js monorepo 2016-12-14 10:02:30 -08:00
Ivo van Dongen
28be37fcbe [core] Swap order of Style::recalculate and Style::relayout
Style::relayout uses source.baseImpl->loaded, a flag which is updated by Style::recalculate. So recalculate first, then relayout.
2016-12-12 16:49:02 -08:00
John Firebaugh
82856fd08b [darwin, android] SDK bindings for circle-stroke properties 2016-12-09 09:35:21 -08:00
John Firebaugh
3b2a4216a2 [core] Implement circle-stroke properties
Also includes stubs for fill-extrusion layer, because most of the code was auto-generated.
2016-12-09 09:35:21 -08:00
Minh Nguyễn
84038832e4 [test] Updated mapbox-gl-test-suite version
Followup to #7123.
2016-12-02 09:11:45 -08:00
Chris Loer
5f29c3ba26 [core] Full support for line breaking bidirectional text using ICU bidi functionality.
- Trim whitespace from labels before determining their max-width for alignment.
 - Fix crash on labels that contain lines with only a single character of whitespace.
2016-11-30 11:54:08 -08:00
Chris Loer
bceeba29a3 [core] Add ICU package for Bidirectional text support and arabic text shaping.
Apply bidi and shaping in symbol_layout.
Add utility functions for converting to and from UTF-16.
2016-11-17 14:33:03 -08:00
John Firebaugh
5c7aeec5c7 [tests] Update test-suite 2016-11-17 13:48:00 -08:00
Molly Lloyd
3380f0803a [core] update native for line property function shaders changes (#6658)
* [core] update shaders for line property functions

update deps, define device pixel ratio for all shaders

[core] create ShaderParameter struct to store pixel ratio and overdraw param

repair rebase errs

update shaders to include pixel ratio

make sure collision_box never overdraws

update test suite, move shaders to Painter::render so the correct pixel ratio is applied

move shader compiling back to the Painter constructor

rebase from shader --> program refactor

re-factor parameters for collisionBox and debug programs

remove unused vars from line-program, move blur math to shader

update core files

remove unecessary files

update shaders PR, remove comments

bump test suite sha

fix formatting, incorporate feedback

refactor program.hpp

* [core] remove line transformations that were moved to the shaders, bump shader sha

* [core] shorten ProgramParameter instantiation

* [core] bump shader+test suite shas
2016-11-16 17:34:33 -08:00
Bruno de Oliveira Abinader
a5ac643166 [build] Updated test-suite 2016-11-17 01:01:15 +01:00
Mike Morris
aeba7cce84 node-v3.4.2 2016-11-15 13:31:48 -05:00
Bruno de Oliveira Abinader
31206b4516 [build] Added nan@2.4.0 dependency 2016-11-15 18:28:30 +01:00
Minh Nguyễn
dbd2235744 [core] Line-break ideographic text by character (#6828)
* [core] Line-break ideographic text by character

Allow a line break to be inserted after any supported Chinese, Japanese, or Yi character in a point-placed label. Balance the lines unless non-ideographic text such as Latin letters are present.

Fixes #1223.

* [core] Moved more character classing into util::i18n

* [core] Detect character properties by Unicode block

* [test] Reenabled ideographic breaking tests
2016-11-14 14:53:21 -08:00
Bruno de Oliveira Abinader
1c79147a84 [android] Update GLSL + ensure binding to OpenGL ES 2.0 2016-11-14 17:45:22 +01:00
Ivo van Dongen
39b0bc0a40 [core] symbol layer - recalculate style on icon/text size changes 2016-11-11 20:18:16 +01:00
Mike Morris
7d2f18b5ed node-v3.4.1 2016-11-10 14:16:31 -05:00
Vladimir Agafonkin
efc427f9bb update to mapbox-gl-shaders with vertex/fragment preludes (#6971) 2016-11-08 15:01:53 -08:00
John Firebaugh
2e76fca473 [tests] Update test-suite 2016-11-07 10:43:06 -08:00
John Firebaugh
aa08796767 [core] Separate pathway for notifying workers of new images/glyphs 2016-11-07 10:16:35 -08:00
Mike Morris
176730bff6 node-v3.4.0 2016-11-04 15:17:03 -04:00
Bruno de Oliveira Abinader
6c30105a53 [build] Update -test-suite 2016-11-04 18:43:08 +02:00
Bruno de Oliveira Abinader
fb9fbef6dd [test] Update mapbox-gl-test-suite hash
Now testing 'query-tests/symbol-features-in/pitched-screen'.
2016-10-25 08:12:31 +03:00
Mike Morris
9da7a4aaf0 [android] add lodash to devDependencies in package.json 2016-10-17 14:01:31 +03:00
John Firebaugh
c1b05c8f5b [tests] Get test-suite back on master branch (#6661) 2016-10-11 14:53:15 -07:00
Bruno de Oliveira Abinader
89f3270f72 [node] Added set{Bearing,Center} + updated -test-suite
This gives the ability to pan and/or rotate the map in a posterior step
after initial render for testing purposes.
2016-10-11 12:10:32 +03:00
John Firebaugh
5891c7028d Update mapbox-gl-shaders to 98a56d 2016-10-10 12:46:52 -07:00
Justin R. Miller
ee4715a821 update style generation code for new style spec enum values docs (#6508)
Documentation for enum values landed in mapbox/mapbox-gl-style-spec#510. 

This updates Android, iOS, and macOS documentation code gen scripts to capitalize on them.
2016-09-30 15:55:46 -07:00
Justin R. Miller
b9fafbc2ee clarify circle color as fill (#6447) 2016-09-23 16:16:47 -07:00
John Firebaugh
ea80168b42 [tests] Update test-suite 2016-09-23 12:52:59 -07:00
Young Hahn
08c08f6705 [core] Don't use depth test unless text is pitch-aligned to map (#6404)
* [core, ios, android] Use `auto` value for properties with calculated defaults

* Fix render tests

* [core] Don't use depth test unless text is pitch-aligned to map.

* Bump mapbox-gl-test-suite

* TransformState pitch is already in radians

* Reduce setDepthSublayer calls

* Bump test suite
2016-09-22 19:51:41 -04:00
Young Hahn
6a2ce352d1 Better handling for undefined icon|text-rotation-alignment (#6253)
* [core, ios, android] Use `auto` value for properties with calculated defaults

* Fix render tests
2016-09-21 16:07:33 -07:00
Mike Morris
da02884433 node-v3.3.3 2016-09-06 20:10:30 -04:00
Thiago Marcos P. Santos
edec56e6c5 [node] switch to NodeRequest member fn callback
For (hopefully) better performance than creating a new v8::Context to
wrap each callback while still avoiding leaking memory with v8::FunctionTemplate.

Adds a JavaScript shim in front of module.exports.Map to wrap the
req.respond API internally and preserve the public callback-passing
API, while still exporting the correct prototype.
2016-09-06 18:14:22 -04:00
John Firebaugh
d6f667a5e7 [core] Observe visibility changes 2016-09-06 14:29:22 -07:00
John Firebaugh
b4864ca9d5 [core] Trigger Source::Impl::reload when a filter or layout property is modified 2016-09-06 14:29:22 -07:00
Bruno de Oliveira Abinader
7d40d6347e [build] Re-enable 'circle-radius/antimeridian' @ test suite 2016-08-19 16:51:01 +03:00
Konstantin Käfer
51391740bf [build] convert build-shaders script from Python to Node.js 2016-08-16 15:29:34 +02:00
Konstantin Käfer
18176605f6 [core] support "scheme": "tms" in TileJSON files 2016-08-16 11:04:30 +02:00
Amy Lee Walton
b0cb8715ed CJK overflow - update to match gl-shader (#5908)
* update vertex array ushorts

* update atlas size

* testing latest cjk test-suite branch

* update shader ref

* update shaders

* update icon buffer

* shaders

* updated tests

* buffer fix

* updated make tests

* annotation expected updates

* final push

* final fonts

* a_data1 removal

* remove cjk-mixed test

* hiring threshold for cjk-chinese

* update to new test suite

* Rename a_data2 to a_data in sdf and icon shaders

* update test-suite sha
2016-08-11 09:49:36 -07:00
Mike Morris
87c1174c06 [node] don't override BUILDTYPE in npm install 2016-08-05 11:42:22 +02:00
Konstantin Käfer
692fe1f3ff [build] switch to CMake
This is very much a work in progress.
2016-08-05 11:42:22 +02:00