s2geometry is Google’s open source geometry library designed for representing, analyzing, and manipulating geometric shapes on a sphere rather than a flat plane. This makes it particularly suited for applications involving geospatial data, such as mapping, spatial indexing, and geographic information systems (GIS). The library provides a robust mathematical framework for spherical geometry, allowing developers to work with polygons, points, and regions on the Earth’s surface using consistent and precise algorithms. Unlike traditional 2D geometry libraries, S2 ensures accuracy over large scales by modeling the globe directly, avoiding distortions caused by map projections. The project includes core C++ support, optional Python bindings, and integrations with Bazel and CMake for flexible builds. It relies on Abseil, OpenSSL, and googletest, and is tested across major platforms.

Features

  • Provides geometry operations for spherical (Earth-like) surfaces
  • Optimized for geospatial applications like mapping and region indexing
  • Supports C++20 and includes optional Python bindings
  • Integrates with Bazel and CMake build systems
  • Cross-platform support for Linux and macOS (with partial Windows compatibility)
  • Based on accurate, efficient algorithms for high-precision geometry computation

Project Samples

Project Activity

See All Activity >

Categories

Mathematics

License

Apache License V2.0

Follow S2 Geometry

S2 Geometry Web Site

Other Useful Business Software
Build Agents and Models on One Platform Icon
Build Agents and Models on One Platform

Everything you need to build production-ready agents and models. Access 200+ Google and third-party AI models and tools.

Gemini Enterprise Agent Platform is Google Cloud's comprehensive platform for developers to build, scale, govern, and optimize agents and models. Choose from Google's most advanced models and third-party models like Anthropic's Claude Model Family.
Try It Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of S2 Geometry!

Additional Project Details

Operating Systems

Linux, Mac, Windows

Programming Language

C++

Related Categories

C++ Mathematics Software

Registered

2025-10-10