[core] fix circle querying for scale and alignment

This fixes circle querying for cases where either
    circle-pitch-alignment=map
or
    circle-pitch-scaling=viewport
This commit is contained in:
Chris Loer
2018-04-02 17:41:55 -07:00
committed by Ansis Brammanis
parent f7d20a5871
commit f86fe44dbd
39 changed files with 186 additions and 68 deletions

View File

@@ -188,14 +188,15 @@ bool RenderFillLayer::queryIntersectsFeature(
const GeometryCoordinates& queryGeometry,
const GeometryTileFeature& feature,
const float,
const float bearing,
const float pixelsToTileUnits) const {
const TransformState& transformState,
const float pixelsToTileUnits,
const mat4&) const {
auto translatedQueryGeometry = FeatureIndex::translateQueryGeometry(
queryGeometry,
evaluated.get<style::FillTranslate>(),
evaluated.get<style::FillTranslateAnchor>(),
bearing,
transformState.getAngle(),
pixelsToTileUnits);
return util::polygonIntersectsMultiPolygon(translatedQueryGeometry.value_or(queryGeometry), feature.getGeometries());