Skip to content

GeoJsonDocumentRasterOverlay does not rasterize Point / MultiPoint geometry #1403

Description

@baruchInsert-tech

Description

CesiumVectorOverlays::GeoJsonDocumentRasterOverlay does not actually rasterize
Point and MultiPoint geometry, even though the changelog for v0.61.0 states
that the document overlay can display points. Points and multi-points are
silently dropped and never appear in the rasterized output.

Steps to reproduce

  1. Build a GeoJsonDocument containing Point and/or MultiPoint geometry.
  2. Create a GeoJsonDocumentRasterOverlay from that document with a
    VectorStyle whose point style is set (fill and/or outline).
  3. Rasterize the overlay.

Expected behavior

Points and multi-points are rendered as filled / outlined circles using
VectorStyle::point, consistent with the v0.61.0 changelog claim that the
document overlay can display points.

Actual behavior

No point geometry is drawn. The points are dropped before reaching the
rasterizer, so the output contains nothing for them.

Root cause

The rasterizer itself already knows how to draw points:
VectorRasterizer::drawGeoJsonObject routes GeoJsonPoint / GeoJsonMultiPoint
to drawPoints(..., style.point). The geometry just never reaches it.

When GeoJsonDocumentRasterOverlay builds its quadtree, addPrimitivesToData
runs RectangleAndLineWidthFromObjectVisitor to compute a bounding rectangle for
each object and only stores objects that produce one (if (rect)). The visitor's
operator() for GeoJsonPoint and GeoJsonMultiPoint are empty, so points
yield no rectangle and are dropped before ever reaching the rasterizer.

Additionally, QuadtreeGeometryData::calculateBoundingRectangleForTileSize has
no Point / MultiPoint branch, so even if points were stored, their per-tile
bounds would fall into the line branch and be sized by style.line instead of
style.point.

Affected version

v0.61.0 (the v0.61.0 changelog already claims the document overlay can display
points, but it cannot).

Notes

A fix is proposed in PR #1400, which implements the Point / MultiPoint
visitor operators, adds a Point / MultiPoint branch to
calculateBoundingRectangleForTileSize, and adds render tests for Point,
outlined Point, and MultiPoint.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Fields

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions