summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlexander Shalamov <alexander.shalamov@mapbox.com>2018-10-23 11:45:10 +0300
committerAlexander Shalamov <alexander.shalamov@mapbox.com>2018-11-19 14:06:21 +0200
commit44906b1ff38cc6ccedd2a10e02a4fa0aa926d967 (patch)
treef354e04599a6a84532b1b72ff2ad839529e96f35 /src
parent527851e2aa71c828f013303c827b90aa496cec15 (diff)
downloadqtlocation-mapboxgl-44906b1ff38cc6ccedd2a10e02a4fa0aa926d967.tar.gz
[core] Remove downcasts for layers that require 3D render pass
Diffstat (limited to 'src')
-rw-r--r--src/mbgl/renderer/renderer_impl.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/mbgl/renderer/renderer_impl.cpp b/src/mbgl/renderer/renderer_impl.cpp
index 306c18759c..129925bd9a 100644
--- a/src/mbgl/renderer/renderer_impl.cpp
+++ b/src/mbgl/renderer/renderer_impl.cpp
@@ -299,13 +299,8 @@ void Renderer::Impl::render(const UpdateParameters& updateParameters) {
RenderLayer* layer = getRenderLayer(layerImpl->id);
assert(layer);
- if (!parameters.staticData.has3D && (
- layer->is<RenderFillExtrusionLayer>() ||
- layer->is<RenderHillshadeLayer>() ||
- layer->is<RenderHeatmapLayer>())) {
-
- parameters.staticData.has3D = true;
- }
+ parameters.staticData.has3D |=
+ (layerImpl->getTypeInfo()->pass3d == LayerTypeInfo::Pass3D::Required);
if (!layer->needsRendering(zoomHistory.lastZoom)) {
continue;