Table of Contents

Class OverscaleEvaluator

Namespace
EncDotNet.S100.Renderers.Mapsui
Assembly
EncDotNet.S100.Renderers.Mapsui.dll

Computes per-cell overscale for the current viewport (issue #441). A chart cell is overscaled when the mariner has zoomed in past the finest scale the cell was compiled for (its CompilationScaleDenominator): the chart is magnified beyond the detail it actually contains. Because compilation scale is a per-cell property, a single view can hold cells overscaled by different amounts (and cells not overscaled at all); this evaluator reports each overscaled cell and the worst offender for the status-bar indicator.

public static class OverscaleEvaluator
Inheritance
OverscaleEvaluator
Inherited Members

Methods

Evaluate(IReadOnlyList<OverscaleCellInput>, Envelope, double)

Evaluates overscale for the supplied cells at the given EPSG:3857 viewport extent and viewportResolution (Web-Mercator metres per pixel). Only cells whose coverage envelope intersects the viewport are counted; each such cell's overscale factor is DenominatorToResolution(compilationDenominator, φ) / viewportResolution, where φ is the latitude of the cell's coverage-envelope centre (so the factor undoes Web-Mercator 1/cos φ distortion, matching the status-bar scale readout and the overlap-suppression cutoffs).

public static OverscaleReport Evaluate(IReadOnlyList<OverscaleCellInput> cells, Envelope viewport, double viewportResolution)

Parameters

cells IReadOnlyList<OverscaleCellInput>

The loaded, drawing, scale-bearing cells.

viewport Envelope

The current view extent in EPSG:3857.

viewportResolution double

The current viewport resolution in Web-Mercator metres per pixel (must be positive; non-positive or non-finite yields None).

Returns

OverscaleReport

The overscale report (never null).