wtimme / OSM-Completionist

⛔️ DEPRECATED iOS companion app for OpenStreetMap that allows contributors to complete missing information
ISC License
18 stars 4 forks source link

Add multiple-choice quests with images #55

Open wtimme opened 4 years ago

wtimme commented 4 years ago

User Story

As a less-experienced mapper, I want multiple-choice quests to have example images, so that I know more easily which answer to choose

Acceptance Criterias

Example

Parking type quest options in StreetComplete

Open questions

westnordost commented 4 years ago

Of course, no need to ask, they are all under an open source license, see https://github.com/westnordost/StreetComplete/blob/master/AUTHORS.md for details.

For the one above:

parking_type_multistorey.jpg   CC-BY-SA 3.0      https://en.wikipedia.org/wiki/File:Hradec_Kr%C3%A1lov%C3%A9,_Resslova,_parkovac%C3%AD_d%C5%AFm.jpg
parking_type_surface.jpg       CC-BY-SA 3.0      https://wiki.openstreetmap.org/wiki/File:Car_park2.jpg
parking_type_underground.jpg   CC0               https://pixabay.com/de/tiefgarage-einfahrt-absch%C3%BCssig-273439/

By the way, a few things changed since a few years ago when I told you that StreetComplete on iOS would be a completely new app because there is nothing (apart from resources) one could share:

  1. I've since converted/refactored 90% of the code to Kotlin and there is Kotlin Native, which enables one to write (Kotlin) code once for any platform, so only the UI and anything OS specific needs to be done for each platform respectively. I've taken care to separate as much application logic as possible from the UI-related classes (i.e. ViewControllers) to make a possible crossplatform project easier. Though, crossplatform-ness only applies for code written in Kotlin, so any Java dependencies and by extension Kotlin code that depends on Java code would not be fit for iOS
  2. There is a little-known project called Multi-OS-Engine. Basically, it runs your JVM code (Java, Kotlin, Scala, ...) also on iOS, within a container and again, only the OS specific things need to be done for each platform respectively. Concept-wise, the advantage this seems to have over Kotlin Native is that even Java libraries could be used for the iOS port and it is just the UI part that would need to be done twice.
  3. (I have a MacBook now ;-) )

I repeatedly thought about telling you about this but I thought you lost interest in this idea for some time already.

It will still be a huge amount of work, but I imagine still a lot less than developing a completely new app.

wtimme commented 4 years ago

Thanks for the quick response, @westnordost! That's great news.

You were correct, creating an own app from scratch requires a lot of effort, which is why I decided to contribute to GoMap!! and add the quest-behaviour to it. GoMap!! is a pretty advanced editor for OSM on iOS, and since it already has a lot of rendering implemented, I was able to create a quick MVP. I'll try to join next month's Mappertreffen - if you had time I would be more than happy to meet you once again in person!


As for this issue, I think we would be good with using the images that were already discussed and selected over at [StreetComplete][/westnordost/StreetComplete], since you guys already put a lot of thought into it.

Thanks by the way for the documentation of your quests! That was pretty helpful in seeing what kind of quests an app could support, and the Overpass Turbo links were a great bonus that allowed me to get started quickly.

westnordost commented 4 years ago

I'll try to join next month's Mappertreffen - if you had time I would be more than happy to meet you once again in person!

Sure, I'll be there!


The documentation is mostly maintained by @rugk, you can thank him :-)

Though, the overpass turbo links might be simplified or out of date. You get the most up-to-date tag filters by looking at the source code.

For example for the AddMaxWeight quest:

ways with highway ~ trunk|trunk_link|primary|primary_link|secondary|secondary_link|tertiary|tertiary_link|unclassified|residential|living_street|service
 and service != driveway
 and !maxweight and maxweight:signed != no
 and !maxaxleload and !maxbogieweight
 and !maxweight:hgv and !maxweight:bus and !maxweight:hgv_articulated and !maxweight:tourist_bus
 and !maxweight:coach
 and !maxweightrating
 and !maxweightrating:hgv and !maxweightrating:bus and !hgv
 and !maxunladenweight
 and !maxunladenweight:hgv and !maxunladenweight:bus
 and bridge and bridge != no
 and motor_vehicle !~ private|no
 and vehicle !~ private|no
 and (access !~ private|no or (foot and foot !~ private|no))
 and area != yes

https://github.com/westnordost/StreetComplete/blob/master/app/src/main/java/de/westnordost/streetcomplete/quests/max_weight/AddMaxWeight.kt

Streetcomplete uses this easier-to-read tag filter syntax which is converted into efficient OQL syntax by this code here (~750 LOC + tests). This little program in the tests directory of the app prints out valid OQL syntax for all quests (that use this simple syntax) in StreetComplete for review and for an overview. I posted the output of that program once somewhere in the StreetComplete issuetracker but for an older version, so if you are after the OQL for all the quests, you should execute this program on master yourself.

rugk commented 4 years ago

Though, the overpass turbo links might be simplified or out of date

Yeah, I still need to get into executing this program there and updating the queries... (though I first of all focused on getting the new quests in there)

westnordost commented 4 years ago

You forgot about the Mappertreffen

wtimme commented 4 years ago

Hey Tobias, I was not feeling well yesterday, which is why I decided to stay home and get some rest. I wrote you a message on Slack, since I figured that‘s the most reliable (and private) way of reaching you. Sorry for the inconvenience! :( I was actually very much looking forward to seeing you again.

westnordost commented 4 years ago

Oh okay. Get well soon! I am not (really) on slack, was there once when I contributed a few things to iD. I am in the telegram channel for OSM Hamburg