Instead of having individual APIs for setting axonometric
and skew options, create ProjectionMode struct that holds
all the relevant options for Axonometric rendering and
introduce setter/getter on the Map for those options.
This patch will make Mapbox GL Core never use OpenGL
directly. We should consider locking into OpenGL ES 2.0
to simplify the code path and remove #ifdefs.
The platform will be responsible to load the OpenGL implementation
and give the function pointers to Mapbox GL Core. The platform might
load OpenGL by linking against some OpenGL implementation, load it
dynamically, etc. It doesn't matter as long as it is a valid
implementation.
Also adds the `::platform` namespace where all the missing symbols and
interfaces expected to be implemented by the platforms will live.
The `useIntegerZoom` presence is now limited: it is removed
from `PossiblyEvaluatedPropertyValue` class specializations
(was never used there!) and from the `PropertyEvaluationParameters`
class, so we do not have to copy `PropertyEvaluationParameters`
instance at `RenderLineLayer::evaluate`.
We used `const std::pair<T, std::shared_ptr<Expression>>`, but the actual type is `const std::pair<const T, std::shared_ptr<Expression>>` which resulted in an implicit copy
The tile sorting can be now removed from the algorithms, which
calculate tile mask and clip ids, because their client code
provides tiles being already sorted (in `TilePyramid`).
This patch brings significant improvements to the Tile-related
performance tests results, for example the `TileMaskGeneration`
benchmark test runs 33 times faster with these changes applied.
Progams code for a certain layer type is encapsulted within
a dedicated `<layer type>Programs` class, inherited from
the generic base `LayerTypePrograms` class.
`mbgl::Programs::get<layer type>Programs()` lazily initializes the
layer type-specific programs code using pointer to the base class,
which allows LTO to remove this code from binaries (if the corresponding
`get<layer type>Programs()` method can never be invoked).