PHPackages                             ycdev/php-osm-static-aero - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. ycdev/php-osm-static-aero

ActiveLibrary

ycdev/php-osm-static-aero
=========================

PHP library to generate static aeronautical maps from OpenStreetMap (OSM) with markers, lines and drawings.

011↓100%[1 PRs](https://github.com/Cym-Developpement/php-osm-static-aero/pulls)PHP

Since Aug 7Pushed 1mo agoCompare

[ Source](https://github.com/Cym-Developpement/php-osm-static-aero)[ Packagist](https://packagist.org/packages/ycdev/php-osm-static-aero)[ RSS](/packages/ycdev-php-osm-static-aero/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (3)Used By (0)

[![GitHub license](https://camo.githubusercontent.com/a752ac0fd5611f8dc629fd0aae1e6b06b4505853184b9a84e9cd4855a2c34c90/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f44616e7453752f7068702d6f736d2d7374617469632d6170692e737667)](https://github.com/DantSu/php-osm-static-api/blob/master/LICENSE)

PHP OSM Static Aero
===================

[](#php-osm-static-aero)

PHP library to generate static aeronautical maps from OpenStreetMap with markers, lines, circles and polygons.

This project is a fork of [php-osm-static-api](https://github.com/DantSu/php-osm-static-api) by [Franck ALARY (DantSu)](https://github.com/DantSu), adapted for aeronautical paper map generation.

This project uses the [Tile Server](https://wiki.openstreetmap.org/wiki/Tile_servers) of the OpenStreetMap Foundation which runs entirely on donated resources, see [Tile Usage Policy](https://operations.osmfoundation.org/policies/tiles/) for more information.

Requirements
------------

[](#requirements)

- PHP &gt;= 7.0
- Extension `gd`
- Extension `curl`

Installation
------------

[](#installation)

```
composer require ycdev/php-osm-static-aero
```

How to use
----------

[](#how-to-use)

### Generate OpenStreetMap static image with markers and polygon :

[](#generate-openstreetmap-static-image-with-markers-and-polygon-)

```
use \Ycdev\OsmStaticAero\OpenStreetMap;
use \Ycdev\OsmStaticAero\LatLng;
use \Ycdev\OsmStaticAero\Polygon;
use \Ycdev\OsmStaticAero\Markers;

\header('Content-type: image/png');
(new OpenStreetMap(new LatLng(44.351933, 2.568113), 17, 600, 400))
    ->addMarkers(
        (new Markers(__DIR__ . '/resources/marker.png'))
            ->setAnchor(Markers::ANCHOR_CENTER, Markers::ANCHOR_BOTTOM)
            ->addMarker(new LatLng(44.351933, 2.568113))
            ->addMarker(new LatLng(44.351510, 2.570020))
            ->addMarker(new LatLng(44.351873, 2.566250))
    )
    ->addDraw(
        (new Polygon('FF0000', 2, 'FF0000DD'))
            ->addPoint(new LatLng(44.351172, 2.571092))
            ->addPoint(new LatLng(44.352097, 2.570045))
            ->addPoint(new LatLng(44.352665, 2.568107))
            ->addPoint(new LatLng(44.352887, 2.566503))
            ->addPoint(new LatLng(44.352806, 2.565972))
            ->addPoint(new LatLng(44.351517, 2.565672))
    )
    ->getImage()
    ->displayPNG();
```

### Align and zoom the map to drawings and markers :

[](#align-and-zoom-the-map-to-drawings-and-markers-)

- `->fitToDraws(int $padding = 0)`
- `->fitToMarkers(int $padding = 0)`
- `->fitToMarkersAndDraws(int $padding = 0)`
- `->fitToPoints(LatLng[] $points, int $padding = 0)`

`$padding` sets the amount of padding in the borders of the map that shouldn't be accounted for when setting the view to fit bounds. This can be positive or negative according to your needs.

Documentation
-------------

[](#documentation)

ClassDescription[Circle](./docs/classes/Ycdev/OsmStaticAero/Circle.md)Draw circle on the map.[Geometry2D](./docs/classes/Ycdev/OsmStaticAero/Geometry2D.md)2D geometry utility methods.[Image](./docs/classes/Ycdev/OsmStaticAero/Image.md)GD-based image editing with tile caching.[LatLng](./docs/classes/Ycdev/OsmStaticAero/LatLng.md)Define latitude and longitude for map, lines, markers.[Line](./docs/classes/Ycdev/OsmStaticAero/Line.md)Draw line on the map.[MapData](./docs/classes/Ycdev/OsmStaticAero/MapData.md)Convert latitude and longitude to image pixel position.[Markers](./docs/classes/Ycdev/OsmStaticAero/Markers.md)Display markers on the map.[OpenStreetMap](./docs/classes/Ycdev/OsmStaticAero/OpenStreetMap.md)Main class to generate static map images.[Polygon](./docs/classes/Ycdev/OsmStaticAero/Polygon.md)Draw polygon on the map.[TileLayer](./docs/classes/Ycdev/OsmStaticAero/TileLayer.md)Define tile server url and related configuration.[XY](./docs/classes/Ycdev/OsmStaticAero/XY.md)Define X and Y pixel position for map, lines, markers.Credits
-------

[](#credits)

This project is based on [php-osm-static-api](https://github.com/DantSu/php-osm-static-api) originally created by [Franck ALARY (DantSu)](https://github.com/DantSu), licensed under the [MIT License](./LICENSE).

Contributing
------------

[](#contributing)

Please fork this repository and contribute back using pull requests.

Any contributions, large or small, major features, bug fixes, are welcomed and appreciated but will be thoroughly reviewed.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance59

Moderate activity, may be stable

Popularity7

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity24

Early-stage or recently created project

 Bus Factor1

Top contributor holds 59.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/024570f0039cd21fa340520a3f616c617734a1634b92a2b5cd137c3954d4c2ec?d=identicon)[cymdev](/maintainers/cymdev)

---

Top Contributors

[![DantSu](https://avatars.githubusercontent.com/u/4188774?v=4)](https://github.com/DantSu "DantSu (44 commits)")[![CymDeveloppement](https://avatars.githubusercontent.com/u/7532413?v=4)](https://github.com/CymDeveloppement "CymDeveloppement (26 commits)")[![cquest](https://avatars.githubusercontent.com/u/1202668?v=4)](https://github.com/cquest "cquest (1 commits)")[![davetha](https://avatars.githubusercontent.com/u/8431567?v=4)](https://github.com/davetha "davetha (1 commits)")[![mandrasch](https://avatars.githubusercontent.com/u/777278?v=4)](https://github.com/mandrasch "mandrasch (1 commits)")[![stephan-strate](https://avatars.githubusercontent.com/u/19595615?v=4)](https://github.com/stephan-strate "stephan-strate (1 commits)")

### Embed Badge

![Health badge](/badges/ycdev-php-osm-static-aero/health.svg)

```
[![Health](https://phpackages.com/badges/ycdev-php-osm-static-aero/health.svg)](https://phpackages.com/packages/ycdev-php-osm-static-aero)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
