-
Notifications
You must be signed in to change notification settings - Fork 553
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
request: regional scoring cell borders #741
Comments
Already on it So far, we know that the grid is a level 6 s2 grid
The exact mapping between the IDs this would use and the names will need to be worked out, but doesn't look too tricky. |
@jonatkins I don't know whether you made something like this yourself, but just in case it may be helpful: I also have some raw data, but no algorithm yet. |
OK, I have enough information to complete this now - it's just a matter of writing the code. Cell ID to name mapping: Face (first 3 bits):
[EDIT: corrected encoding] First 4 bits of cell 'j' value:
Cell ID bits: skip first 8 bits (handled above on i/j bits instead), then 4 bits as 00 to 15 Additionally, some regions (AS, possibly PA and ST too) flip the cell I/J values before running the above. So far I have most of the needed maths written. Final bit to implement is the Hilbert space-filling curve - the reference C++ code is heavily optimised and assumes unsigned 64 bit integers, so can't directly port this. |
Do you have a latlng conversion algorithm? |
I've pushed my work in progress - 0afd23c If you look at the presentation linked above, I've basically got as far as slide 8 The last stage, if following the source directly, requires 64 bit integers. Javascript only has floats, so not possible to directly convert. I'm thinking of handling the cell ID as an array - possibly [face,4bits,4bits,4bits,...] |
At least Firefox has UInt64 objects, but I don't know about chrome/WebView... |
as of e63678c names are working, as far as I can tell, correctly in
It is NOT working in
No examples found for
Asia could probably be 'fixed' by swapping the I/J components - but I want to be sure there's not an underlying issue in the s2cell code before doing this in the name decoding. |
example problem areas: |
Do you guys know about this? http://ingress-cells.appspot.com/ |
yes, @MonoTovarisj - they've been very helpful too as of 022a918 and d645064 I believe the cell names are now correct. AS (asia) now works correctly. Not seen examples of PA or ST, but IngressCells says the same fix should work for PA (pacific) too. I've assumed it's also needed for ST (southern) but have not yet seen an example. |
Here's hoping they just directly add this info to the intel site. The local scoreboard rides again. |
Not sure if it helps, but Hobart is located in ST Hobart: http://ingress-cells.appspot.com/?q=Hobart Portland, Victoria Hope this helps. SCRATCH THAT! |
The core functionality is done. and I've had confirmation from each of the six 'faces' that IITC is correct now. I may still make dome display improvements, particularly in positioning of the names when zoomed in, but will close this issue. Hopefully the stock intel site gets an update to show the scores soon, so IITC can then do the same. |
For sure it would be nice to see the regional scoring cell borders and names in an iitc plugin! There´s obviously some work to gather the info, but that probably could be "crowdsourced" if there was a way to report them.
The text was updated successfully, but these errors were encountered: