# Aerial references

The aerial atlas covers the archive area around Rörstrandsgatan, Norrbackagatan and Hagastaden, with a small rectangular margin. It includes city orthophotos from 2022, 2015 and 2006, and selected original oblique photographs from Wikimedia Commons. The atlas runs from local hosted files; viewing does not depend on a third-party map server.

## Image files and dates

- **2022:** 34 JPEG tiles containing imagery (from a 48-tile grid), each 3,200 × 3,200 pixels covering 256 × 256 metres. The complete GeoTIFF is 19,200 × 25,600 pixels, exported at 8 cm per pixel.
- **2015 and 2006:** 12 JPEG tiles per year, each 1,600 × 1,600 pixels covering 512 × 512 metres. Each complete GeoTIFF is 4,800 × 6,400 pixels, exported at 32 cm per pixel. These are deliberately coarser historical comparisons. The city's nominal source resolution is 8 cm for 2015 and 20 cm for 2006.
- The 58 tiles containing imagery are pieces of **three survey mosaics**, not 58 independent camera exposures. Fourteen completely blank 2022 responses are retained in the acquisition folder but excluded from the aerial browsing index. Partly blank tiles remain, with a rough nonwhite-pixel fraction in their metadata. The JPEG files preserve the WMS response bytes. They are processed orthophotos, not raw photographs from the survey camera.
- Survey year comes from the WMS layer name. Exact acquisition days for these particular tiles are not supplied. Metadata for the separate 2023 product had conflicting 2023/2025 dates; that product was not collected.
- Oblique photographs retain the original Commons files, image dimensions, creator, license, source link and hash. Some 2013 files are alternate crops from the same exposure. The two 1938 views have scan dates in source EXIF; their imagery year is corrected from the source title/description and the raw source date is retained.

## Coordinates and 3D alignment

All city tiles and GeoTIFFs use **EPSG:3011, SWEREF 99 18 00**, with bounds `[151040, 6580096, 152576, 6582144]` in metres. Bounds are west, south, east, north. A tile's GeoJSON polygon describes its image extent, not a camera position.

Each JPEG has a `.jgw` world file and `.prj` CRS file beside it. Keep the three files together. JGW values locate pixel centres; JSON bounds locate outer pixel edges. QGIS and GDAL can open the GeoTIFF directly or the JPEG with its sidecars.

The existing building OBJ uses **EPSG:3006 with a local origin**, so do not apply EPSG:3011 coordinates directly to it. Read `exports/georeference.json`. The aerial tile JSON provides `local_xy_corners_m` already transformed to the same local origin, ordered southwest, southeast, northeast, northwest. These can place a textured quad with UV coordinates `(0,0), (1,0), (1,1), (0,1)` when the image convention has its first row at the top. Image-library UV conventions can differ; check north and the route before final alignment. Use the OBJ's vertical datum for any terrain elevation; the orthophoto supplies no height.

Alternatively reproject a GeoTIFF to EPSG:3006 in QGIS/GDAL, then subtract the existing model origin. For an LLM or script, intersect a building's WGS84 footprint with `api/v1/aerial/footprints.geojson`, then follow the matching record and image links.

Whole-survey GeoTIFFs use lossless DEFLATE compression of the decoded source JPEG pixels. They introduce no resizing or additional lossy compression. The small overview JPEGs are resampled to 1 metre per pixel for browsing.

An 8 cm pixel size is not a claim of 8 cm positional accuracy. Roof edges can lean in ground orthophotos; shadows and occlusion hide details. Construction in Hagastaden has changed since these surveys. Coverage can be blank beyond the city's source imagery, especially toward Solna. Oblique images are uncalibrated visual references, not a complete photogrammetry sequence.

## Sources and reuse information

- [Stockholm city orthophoto information](https://kartor.stockholm/kartor-geodata/) identifies older orthophotos as open geodata and gives source ground resolutions.
- [Stockholm open-data information](https://start.stockholm/om-stockholms-stad/utredningar-statistik-och-fakta/oppna-data/) describes open data as reusable and shareable.
- The [JOSM imagery registry](https://josm.openstreetmap.de/wiki/Maps/Sweden) lists the public 2022 Stockholm orthophoto service and labels it CC0. The service's capabilities still contain a conflicting generic all-rights-reserved notice. This archive preserves the conflicting statements and credits the city; it does not claim a separately verified CC0 waiver. Each tile carries this rights note.
- [City WMS technical guidance](https://kartor.stockholm.se/bios/site/Spec_openmap/Information_om_Baggis_WMS.pdf) documents the image service. Requests use WMS 1.1.1, EPSG:3011 and the advertised `image/jpg` format, with two concurrent requests over this bounded area.
- Oblique files were selected from [Aerial views of Vasastan](https://commons.wikimedia.org/wiki/Category:Aerial_views_of_Vasastan). Their individual Commons licenses are authoritative for those images.

City documentation, WMS capabilities and discovery responses are retained under `data/raw/aerial/`. Every tile records its request, retrieval time, byte count, SHA-256 hash and coordinate conventions. The original JPEG responses are under `data/aerial/stockholm/`; derived mosaics and the machine-readable manifest are under `exports/aerial/`.

To refresh using the same bounded plan: `uv run python collect_aerial.py --commons --orthos --build`. Completed image downloads are reused after checksum validation. Provider throttling stops the relevant download pass; unattempted files remain pending.
