smartmet-library-trax

April 22, 2026 · View on GitHub

Part of SmartMet Server. See the SmartMet Server documentation for an overview of the ecosystem.

A high-performance C++ library for generating isobands (filled contour polygons) and isolines (contour lines) from 2D gridded scalar data. Developed by the Finnish Meteorological Institute (FMI) as part of the SmartMet server platform.

Key features:

  • Marching-squares contouring with native NaN (missing-value) handling
  • Three interpolation modes: linear, midpoint (nearest-neighbour), and logarithmic
  • Optional bilinear cell subdivision (Contour::subdivide(n), n up to 10) that replaces the straight marching-squares diamond between edge intersections with n-1 samples on the true bilinear level curve
  • Explicit missing-value isobands and isolines for contouring NaN regions
  • Open-ended isobands using ±infinity limits
  • Global grid wrap-around support
  • Output as WKT, WKB, OGR geometry, or GEOS geometry

Documentation