Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MeshMap: add setting to hide location precision circles #921

Conversation

powersjcb
Copy link
Contributor

@powersjcb powersjcb commented Sep 8, 2024

Resolves: #920

What changed?

Added menu option to hide location precision circles for nodes

Why did it change?

Allows for cleaner UIs when map areas have users with very low location precision

How is this tested?

Manually on iPhone

Screenshots/Videos (when applicable)

RPReplay_Final1725837447.mov

Checklist

  • My code adheres to the project's coding and style guidelines.
  • I have conducted a self-review of my code.
  • I have commented my code, particularly in complex areas.
  • I have made corresponding changes to the documentation.
  • I have tested the change to ensure that it works as intended.

@powersjcb powersjcb changed the title Powersjcb/option to disable circles of uncertainty on maps MeshMap: add setting to hide location precision circles Sep 8, 2024
@powersjcb
Copy link
Contributor Author

powersjcb commented Sep 8, 2024

I'm blocked testing this change at the moment since I don't have the ability to load real node data.

update: resolved - will open a PR documenting how to get the app building for an iphone without being added to the core contributor group

@@ -96,6 +97,9 @@ extension UserDefaults {

@UserDefault(.meshMapDistance, defaultValue: 800000)
static var meshMapDistance: Double

@UserDefault(.meshMapShowLocationPrecision, defaultValue: true)
Copy link
Contributor Author

@powersjcb powersjcb Sep 8, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there's three default values related to these configs (which is a bit confusing)

@powersjcb
Copy link
Contributor Author

I finally figured out how to get this compiling for my phone. However, even with the business logic disabled that hides location precision I'm only seeing a circle on the map for my own node.

TBD what's going on here, but I suspect we only ingest position precision when the iphone app sees certain events have happened.

Copy link
Member

@garthvh garthvh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since most locations are going to be imprecise now I am not a huge fan of this change, if we did implement it, it would need to filter the data in the query and not just hide the circle, we don't use user defaults for the filters.

@powersjcb
Copy link
Contributor Author

powersjcb commented Sep 11, 2024

At the moment, this is just an attempt to allow users to "opt-out of clutter" if they don't care about knowing how precise node positions are.

See this example where entire regions of the map are filled by Location Precision Circles for nodes that have ranges of 5mi and 15mi. When zoomed in the entire map has fill colors driven by the two nodes.

image image image

@garthvh, as a more minimalist change, what would you think about removing or allowing users to toggle fill color for Location Precision Circles?

This wouldn't change the ability to see uncertainty, but it would prevent very large Location Precision Circles from applying fill color for all the areas of the map they encapsulate. (which can contain many nodes)

Separately, do you have any sense for how stable we are with this UI? Given the comments on reddit, it feels like it would be helpful to build a tooltip map-legend UI once it's stable.

Press (?) icon on map -> launch modal with map-legend.

@powersjcb
Copy link
Contributor Author

powersjcb commented Sep 11, 2024

This might need some tweaks to edge color to make it more visible, but it doesn't mess with the map colors within the bounds of the circle.

image

@garthvh
Copy link
Member

garthvh commented Sep 13, 2024

I really am not seeing a need for this right now, the circles are like 20% and several can stack fine on top of each other. May revisit after 2.5 is the majority firmware.

@garthvh garthvh closed this Sep 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🚀 [Feature Request]: allow users to hide node "possible locations" ranges on MeshMap
2 participants