Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
zmiao authored and alexshalamov committed Feb 28, 2020
1 parent a78aef7 commit 3a88706
Show file tree
Hide file tree
Showing 6 changed files with 427 additions and 449 deletions.
10 changes: 1 addition & 9 deletions src/mbgl/layout/symbol_projection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -411,15 +411,7 @@ namespace mbgl {
fontSize * perspectiveRatio :
fontSize / perspectiveRatio;

const auto transformedTileAnchor = project(placedSymbol.anchorPoint, labelPlaneMatrix);

// Skip labels behind the camera
if (transformedTileAnchor.second <= 0.0) {
hideGlyphs(placedSymbol.glyphOffsets.size(), dynamicVertexArray);
continue;
}

const Point<float> anchorPoint = transformedTileAnchor.first;
const Point<float> anchorPoint = project(placedSymbol.anchorPoint, labelPlaneMatrix).first;

PlacementResult placeUnflipped = placeGlyphsAlongLine(placedSymbol, pitchScaledFontSize, false /*unflipped*/, keepUpright, posMatrix, labelPlaneMatrix, glCoordMatrix, dynamicVertexArray, anchorPoint, state.getSize().aspectRatio());

Expand Down
Loading

0 comments on commit 3a88706

Please sign in to comment.