Count what a route corridor touches
Route options are compared on what they touch. This example draws a 50 m corridor along Tbilisi's rail and metro lines and picks out every building inside it, from OpenStreetMap.
Buildings within 50 m of Tbilisi's rail and metro lines
Data: OpenStreetMap rail and metro lines, and buildings
Method: keep every building within 50 m of a line, measured on the ellipsoid
-- Buildings within 50 m of a rail or metro line
WITH rail AS (
SELECT geom FROM osm.public_transport_line
WHERE osm_type = 'railway' AND osm_subtype IN ('rail', 'subway')
AND geom && ST_MakeEnvelope(44.70, 41.65, 44.90, 41.80, 4326)
)
SELECT b.osm_id, b.osm_subtype AS building, b.name, b.geom
FROM osm.building_polygon AS b
WHERE b.osm_type = 'building'
AND b.geom && ST_MakeEnvelope(44.70, 41.65, 44.90, 41.80, 4326)
AND EXISTS (
SELECT 1 FROM rail AS r
WHERE r.geom && ST_Expand(b.geom, 0.001)
AND ST_DWithin(b.geom::geography, r.geom::geography, 50)
);
The geography cast makes 50 mean metres without choosing a projection. Most of these buildings carry no building type in OpenStreetMap, so a breakdown by type is partial.
Run it on your data
Upload your alignment as GeoJSON, Shapefile, KML or GPX and swap it in for the rail step; the corridor and the buildings it catches land as layers on the map. Replace the OpenStreetMap buildings with your own parcels or asset register the same way, and export the map to QGIS for detailed design work. See supported files.
Frequently asked questions
How precise is the corridor?
As precise as the route you upload and the projection used. OpenStreetMap buildings are not survey data.
Can I compare two alignments?
Upload both routes and run the same query against each. The results land as separate layers.