summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksandar Stojiljkovic <aleksandar.stojiljkovic@mapbox.com>2020-03-01 09:58:08 +0200
committerAleksandar Stojiljkovic <aleksandar.stojiljkovic@mapbox.com>2020-03-01 10:21:37 +0200
commit5c1a7b1ad9057840edee89071227e6b7a0d4f48d (patch)
tree2cecdaf6f520aef1a59c451f5a971ef6907a0ad4
parent6bed2079e3097336547ac01dda3768caadf0c441 (diff)
downloadqtlocation-mapboxgl-upstream/astojilj-depth-heatmap-offscreen.tar.gz
Disable depth in heatmap offscreen rendering.upstream/astojilj-depth-heatmap-offscreen
It triggers Metal depth stencil validation error since depth test is enabled with no depth attachment.
-rw-r--r--src/mbgl/renderer/layers/render_heatmap_layer.cpp28
1 files changed, 13 insertions, 15 deletions
diff --git a/src/mbgl/renderer/layers/render_heatmap_layer.cpp b/src/mbgl/renderer/layers/render_heatmap_layer.cpp
index 5f3c36e440..03a7d12fc4 100644
--- a/src/mbgl/renderer/layers/render_heatmap_layer.cpp
+++ b/src/mbgl/renderer/layers/render_heatmap_layer.cpp
@@ -130,21 +130,19 @@ void RenderHeatmapLayer::render(PaintParameters& parameters) {
checkRenderability(parameters, programInstance.activeBindingCount(allAttributeBindings));
- programInstance.draw(
- parameters.context,
- *renderPass,
- gfx::Triangles(),
- parameters.depthModeForSublayer(0, gfx::DepthMaskType::ReadOnly),
- gfx::StencilMode::disabled(),
- gfx::ColorMode::additive(),
- gfx::CullFaceMode::disabled(),
- *bucket.indexBuffer,
- bucket.segments,
- allUniformValues,
- allAttributeBindings,
- HeatmapProgram::TextureBindings{},
- getID()
- );
+ programInstance.draw(parameters.context,
+ *renderPass,
+ gfx::Triangles(),
+ gfx::DepthMode::disabled(),
+ gfx::StencilMode::disabled(),
+ gfx::ColorMode::additive(),
+ gfx::CullFaceMode::disabled(),
+ *bucket.indexBuffer,
+ bucket.segments,
+ allUniformValues,
+ allAttributeBindings,
+ HeatmapProgram::TextureBindings{},
+ getID());
}
} else if (parameters.pass == RenderPass::Translucent) {