philsupertramp / cyclewaySprites

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

run with:

./main.py > main.log && cat main.log | sort -u -o main.sort.log

(creates a log file and sorts the log-output for further development)

Example

This project focuses on generating svg files representing examples for groups of openstreetmap tags for ways. I.e.

Table

example image (reference, not svg) Way 1 Way 2 Way 3
highwayroad
cycleway:rightseparate
bicycle:bothuse_sidepath
sidewalk:rightseparate
cycleway:leftno
sidewalk:leftno
highwaycycleway
bicycledesignated
bicycle:onewayno
traffic_signDE:237;1000-31
highwayfootway
footwaysidewalk

from json

{
    "tags": [{
            "Way 1": {
                "highway": "road",
                "cycleway:right": "separate",
                "bicycle:both": "use_sidepath",
                "sidewalk:right": "separate",
                "cycleway:left": "no",
                "sidewalk:left": "no"
            },
            "Way 2": {
                "highway": "cycleway",
                "bicycle": "designated",
                "bicycle:oneway": "no",
                "traffic_sign": "DE:237;1000-31"
            },
            "Way 3": {
                "highway": "footway",
                "footway": "sidewalk"
            }
        }
    ]
}

File structure

file / folder short explanation
├── README.md
├── main.py main
├── main.log log
├── main.sort.log sorted log, contains not yet recognized (programmed) tags
├── drawing.py creates svg files from tags
├── settings.py generated default settings json and reads/writes settings json
├── draw_settings.json general settings how to draw some elements
├── tagging.py generate example / read / write tags.json
├── tags.json list of groups of ways tags to render
├── svg folder with output svg files
├── svg.html summary file with svg files in a table
├── generate.sh old script that generated images, which are now used as a reference
├── tagging.html old image summary, now reference
├── tagging.md old reference markdown file, now reference, same content as tagging.html
├── img_intermediate
├── img_result old images which are now used as reference
├── img_src old image source which were used by generate.sh

About


Languages

Language:HTML 63.7%Language:Python 30.7%Language:Shell 5.6%