Commit Graph

313 Commits

Author SHA1 Message Date
Konstantin Käfer
51391740bf [build] convert build-shaders script from Python to Node.js 2016-08-16 15:29:34 +02:00
Fredrik Karlsson
2354c87411 Runtime styling API for iOS/macOS (#5727)
* [ios] wip runtime styling

* [ios, macos] Outlined header templates

* [ios, macos] cleanup and use appropiate data types

* [ios, macos] removed refs to mbgl and added convenient color methods on UIColor and NSColor

* [ios, macos] updated header template, included doc string

* [ios, macos] outlined template for layer implementation files

* [ios, macos] moved script to platform/darwin and updated comments

* [ios, macos] Cleaned up the implementation template

* [ios, macos] removed unused function and added support for more datatypes

* [ios, macos] overhauling the type protocols

* [ios, macos] removed unnecessary style classes

* [ios, macos] added support for more types

* [ios, macos] fixed string and number prop values

* [ios, macos] enum getters

* [ios, macos] added removeLayer() and removed unused layer ref

* [ios, macos] fixed remaining layer types and converted style layer into a protocol

* [ios, macos] fixed addLayer() and added example for line layer

* [ios] GeoJSON source now works

* [ios] fixed raster layer and raster source

* [ios] fixed attr prop number and outlined prop function

* [ios] wip functions

* [ios] bool and float function fix

* [ios] cleanup

* [macos] fixed support for macos

* [ios] fixed string functions

* [ios] extended array functions

* [ios] added tests and fixed a few bugs

* [ios] less verbose functions and improved tests

* [ios, macos] Removed unnecessary use of default arguments

Default arguments aren’t supported in Node v4, and they aren’t needed here anyways, because we’re only testing for truthiness.

* [ios, macos] Enum setters

Rely on a macro instead of category methods to specialize the setter implementation for enum attributes, since generic types are disallowed in Objective-C method signatures and mbgl::style::PropertyType must be type-qualified.

* [ios, macos] Got macOS closer to parity w/ iOS

Added various classes and test classes to the macOS workspace. Also fixed lots of compiler errors and updated macosapp runtime styling example to use the new dictionary syntax for function stops.

Updated all conversions from Objective-C stops to C++ stops to enumerate over the dictionary. Fixed compiler errors in enum setter implementations.

Also corrected path to script in generated file comments.

* [ios, macos] Added EJS templates to project

* [ios, macos] Code formatting

Made code format more consistent.

* [ios, macos] Spelled out ID

Cocoa convention is to always spell out “ID” as “identifier”, in part to avoid confusion with the id keyword. Also, URL is capitalized in most contexts, including property names.

* [ios, macos] Grouped related headers together

* [ios, macos] Cleaned up layer transformation

Also added support for converting background layers into Objective-C.

* [ios, macos] Cleaned up tests

Also made the tests work on macOS by introducing a new window to host the map.

* [ios, macos] Replaced TODOs with #warnings

* [ios] convert array based property values

* [ios, macos] color function/undefined getter

* [ios, macos] fixed function/undefined getters for bool and float properties

* [ios, macos] more function/undefined property getters

* [ios, macos] more type conversion and cleanup

* [ios, macos] disable macos runtime styling tests for now

* [ios, macos] cleaned up style code script

* [ios, macos] more type conversion

* [ios] added a base layer to handle visibility min/max zoom

* [macos] fixed base layer

* [ios, macos] use accessor methods

* [ios, macos] cleanup

* [ios, macos] add geojson to ios and macos

* [macos] rebase fix

* [ios, macos] fixed enum getters and added tests for enums

* [ios, macos] added an update method to base layer

* [ios, macos] added some documentation

* [ios, macos] docs

* [ios, macos] removed refs to filters for now

* [ios, macos] various tail work

* [ios, macos] missing import and incorrect type
2016-08-11 13:14:45 -04:00
Ivo van Dongen
66d8c00376 [android] #5886 - added style code generation for android back in 2016-08-08 09:05:30 -04:00
Konstantin Käfer
cf047b4f95 [build] forward V=1 to ninja builds 2016-08-05 11:42:22 +02:00
Konstantin Käfer
da37ba1822 [build] add missing files to Android build 2016-08-05 11:42:22 +02:00
Konstantin Käfer
131cd8a547 [build] Fix Qt4 build on OS X 2016-08-05 11:42:22 +02:00
Konstantin Käfer
95b6d48b71 [build] use cmake script bundled with Mason 2016-08-05 11:42:22 +02:00
Konstantin Käfer
140908568b [build] make android targets .PHONY and adhere to naming scheme 2016-08-05 11:42:22 +02:00
Konstantin Käfer
e46b580c67 [build] unify naming of Makefile targets
`make foo` just builds
`make run-foo` builds and runs
2016-08-05 11:42:22 +02:00
Konstantin Käfer
2b59061199 [build] add Xcode project for Qt builds 2016-08-05 11:42:22 +02:00
Ivo van Dongen
5f70a65a2c [build] cmake android 2016-08-05 11:42:22 +02:00
Bruno de Oliveira Abinader
0fb3b6e333 [build] Re-enable coverage run 2016-08-05 11:42:22 +02:00
Bruno de Oliveira Abinader
023ff83d88 [build] Fix 'make tidy' on linux 2016-08-05 11:42:22 +02:00
Thiago Marcos P. Santos
6b44aa9095 [build] Use cxx11abi suffix when needed 2016-08-05 11:42:22 +02:00
Thiago Marcos P. Santos
821e58fdc1 [build] Build Qt with CMake 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
Ivo van Dongen
9a3eadfd5b [android] #5610 - Initial Runtime Style Bindings
[android] #5610 - Adjusted public api after discussion

[android] #5610 - added jni binding for NativeMapView#getLayer

[android] #5610 - Added initial test Activity

[android] #5610 - Started on NativePeer implementation for Layer

[android] #5610 - replaced low-level jni code with high-level for native getLayer

[android] 5610 - completed basic layer peer class - constructible from java and c++

[android] #5610 - removed reference that was redundant and causing the finalizer exception

[android] #5610 - Added a property peer

[android] #5610 - added value type to do type conversions - wip

[android] #5610 - simplified property conversion approach - wrapped value with jenv

[android] #5610 - added some more value conversions

[android] #5610 - Finished conversion for basic types

[android] #5610 - allow color's to be set as either an android color int or a String to support all formats in the spec

[android] #5610 - encode color ints as rgba to retain alpha channel

[android] #5610 - recalculate classes after paint property

[android] #5610 - more examples

[android] #5610 - fixed the example

[android] #5610 - cleaned up example code before continueing

[android] #5610 - added layout property example

[android] #5610 - set visibility on layer

[android] #5610 - added removeLayer and example

[android] #5610 - added more type conversions

[android] #5610 - Started on peer classes for layer implementations - WIP

[android] #5610 - First complete layer subclass peer implementation

[android] #5610 - added a little bit of structure before adding the other layer types

[android] #5610 - generate the c++ headers from the style spec

[android] #5610 - make sure the visibility is set as a string

[android] #5610 - Generate c++ layer peer class implementations from the style spec

[android] #5610 - generate java layer peer classes

[android] #5610 - cleanup comments

[android] #5610 - register all c++ peer classes with jni

[android] #5610 - addLayer

[android] #5610 - comment out broken case

[android] #5610 - Sources api - very much WIP

[android] 5610 - GeoJson source implementation and geojson conversion

[android] #5610 - cleanup add source/layer example a bit

[android] #5610 - initial filter api

[android] #5610 - Added filter api on the relevant Layer classes

[android] #5610 - raster layer is not filterable

[android] #5610 - actually make it compile

[android] #5610 - completed filter implementation

[android] #5610 - Vector and Raster Source + examples

[android] #5610 - removed superfluous interface, moved filters to the correct package

[android] #5610 - fixed comments

[android] #5610 - moved tests to the right package

[android] #5610 - hide difference between paint and layout properties in public api, make more performant set method for proeprties

[android] #5610 - fix rebase issue
2016-07-26 16:29:26 -04:00
Mike Morris
480be63396 [node] move memory growth test into separate npm script
webp support in memory test
2016-07-14 13:47:02 -04:00
Jesse Bounds
23caa9f7aa Merge branch 'release-ios-v3.3.0' into master 2016-07-07 15:40:07 -07:00
Jesse Bounds
687013bc99 [ios] Add support for full Bitcode builds (#5586)
In https://github.com/mapbox/mapbox-gl-native/commit/
f791eb32b9 we simplified the package
script and intended to remove support for building the SDK without
Bitcode support. The intention was to use the ENABLE_BITCODE project
setting to do this and remove the control of that variable in the
script. However, since we use `xcodebuild build` this only uses
bitcode `marker` by default and causes a failure when an app that uses
the Mapbox SDK is archived.

This adds the `BITCODE_GENERATION_MODE` and `bitcode` value to the
necessary iOS SDK and mbgl and platform targets. If the SDK is compiled
with these flags set, it will be successfully processed in the bitcode
phase in an app archive operation.

This also removes the `BITCODE` flag from the Makefile since the
intention is to not support building the SDK without bitcode support
and the presence of that option might be confusing.
2016-07-06 08:09:10 -07:00
Bruno de Oliveira Abinader
da863c6e52 [build] Added 'lint' Make target 2016-07-01 11:18:53 +03:00
Mike Morris
bc24da11b2 [node] add BUILDTYPE=Debug support to make node 2016-06-24 14:39:06 -04:00
Thiago Marcos P. Santos
7ea0a0db32 [tests] Run memory tests on travis
Qt4 will run tests with libjemalloc.so. The Memory.Footprint and
the Memory.Fragmentation will only run with libjemalloc.so because
we have then a better control over the results.
2016-06-21 19:12:32 +02:00
Bruno de Oliveira Abinader
87a09c51ee [build/qt] Use platform-specific gyp flavor when cross-compiling 2016-06-19 12:40:49 +03:00
Bruno de Oliveira Abinader
e50980793a [build] Use mason platform info when cross-compiling
Build platform equals to host platform if not cross compiling, otherwise
use the mason-provided platform.
2016-06-19 12:18:58 +03:00
Minh Nguyễn
061854990f [macos] Renamed OS X SDK to macOS SDK
Also renamed as many references to OS X as possible to macOS in documentation.

Cherry-picked from b9702ef41a.
2016-06-18 14:58:07 -07:00
Bruno de Oliveira Abinader
3f024ebaf0 [Qt] Install valgrind on-demand 2016-06-16 19:30:20 +03:00
Bruno de Oliveira Abinader
fe64238b4c [tidy] Switched to Travis CI
Fixes https://github.com/mapbox/mapbox-gl-native/issues/5341.
2016-06-14 22:38:40 +03:00
Bruno de Oliveira Abinader
b00e6fc7e1 [tidy] Install mason clang-tidy if CLANG_TIDY is not set
Also added HeaderFilterRegex to .clang-tidy.
2016-06-14 12:20:08 +03:00
Minh Nguyễn
b9702ef41a [macos] Renamed OS X SDK to macOS SDK
Also renamed as many references to OS X as possible to macOS in documentation.
2016-06-14 10:02:06 +02:00
Bruno de Oliveira Abinader
fe09510c1b [build] Re-enable tidy checks 2016-06-13 23:32:07 +03:00
Bruno de Oliveira Abinader
bfd1d9d1bf [build] compdb depends on node_modules 2016-06-13 23:32:06 +03:00
Bruno de Oliveira Abinader
62d355ab15 [build] Make node_modules non-parallel 2016-06-12 11:31:55 +03:00
Bruno de Oliveira Abinader
83a3c18bdb [build] Update compdb & tidy for Linux & OS X 2016-06-10 17:35:01 +03:00
Thiago Marcos P. Santos
8bbb721636 [Qt][build] Updated valgrind supression and make it a target for Qt 2016-06-09 19:56:35 +03:00
Konstantin Käfer
0fe60d398e [build] add benchmark target 2016-06-06 13:50:55 +02:00
John Firebaugh
a758b41b06 [build] Fix mason submodule initialization 2016-06-03 09:51:39 -07:00
John Firebaugh
a43940afb2 [core] Runtime style layer API 2016-06-02 14:51:39 -07:00
John Firebaugh
8068424f30 [build] Add android-* make targets for specific ABIs 2016-06-01 17:37:01 -07:00
Bruno de Oliveira Abinader
bdeabc492c Revert "[build] Use 'npm update --dev' to install devDependencies"
This reverts commit f4ebda09be.
2016-05-26 16:16:15 +03:00
Bruno de Oliveira Abinader
f4ebda09be [build] Use 'npm update --dev' to install devDependencies 2016-05-26 15:00:55 +03:00
John Firebaugh
45c5b2a66c [core] Share shaders with gl-js 2016-05-25 21:37:58 -07:00
John Firebaugh
2846e2a424 [build] Move express dependency to package.json 2016-05-25 21:37:17 -07:00
John Firebaugh
9732f02422 [build] Switch default BUILDTYPE to Debug 2016-05-24 09:55:13 -07:00
John Firebaugh
fc1c21202a [build] Use test-$(HOST_PLATFORM) as default make target 2016-05-24 09:55:13 -07:00
John Firebaugh
eb03611943 [build] Make gyp commands more consistent 2016-05-24 09:55:13 -07:00
John Firebaugh
a6e0870a3a [build] Add appropriate platform.gyp dependencies 2016-05-24 09:55:13 -07:00
John Firebaugh
35de561bb4 [build] Introduce CONFIG_DEPENDENCIES 2016-05-24 09:55:13 -07:00
John Firebaugh
c02d837a33 [build] Add GYP_DEPENDENCIES to all appropriate targets 2016-05-24 09:55:02 -07:00
Bruno de Oliveira Abinader
6938970dcc [build] Fix Qt build for OS X 2016-05-24 19:32:55 +03:00