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

Merging states #66

Open
hockeymikey opened this issue Dec 18, 2022 · 7 comments
Open

Merging states #66

hockeymikey opened this issue Dec 18, 2022 · 7 comments
Labels
enhancement New feature or request

Comments

@hockeymikey
Copy link

Is there anyway to merge some state files, like California for example? It's mostly cosmetic reasons, so OSMand shows the states I have as green. It only expects one file. I tried renaming it to the Us_state_(region_?)_northamerica format with no luck (did work for other states without subregion files).

@pnoll1
Copy link
Owner

pnoll1 commented Dec 23, 2022

The docs I found suggest large files will cause issues so you don’t want to try to merge files.

You could try renaming one of the files Us_california.obf to see if that would trick Osmand into showing green for the whole state.

The real question is where does Osmand get the coverage information from?

@hockeymikey
Copy link
Author

@pnoll1 Interesting, I wonder why they serve big files themselves (like a 1gb+ CA file). I think that would work, I renamed one and all of CA lit up. Renaming one wouldn't cause issues of being picked up by OSMAnd, correct?
I'm not sure, it must be custom. You can download custom sets like LA area or bakersfield in CA and it will only make green those respective areas. And it's purely based on the name/conventions.

@pnoll1
Copy link
Owner

pnoll1 commented Dec 24, 2022

Doc said to avoid files over 2GB so it's probably fine.

Renaming one wouldn't cause issues of being picked up by OSMAnd, correct?

Probably not, if it seems weird just restart the app and/or reload the file.

I'm not sure, it must be custom. You can download custom sets like LA area or bakersfield in CA and it will only make green those respective areas. And it's purely based on the name/conventions.

Sure, it's just weird that they don't seem to pull that info from the map files or there's an undocumented map creator setting that needs to be turned on.

@hockeymikey
Copy link
Author

@pnoll1
Its must be contained in: https://github.com/osmandapp/OsmAnd-resources/blob/877490a6e76960557135c881b0a870cc51e286d5/countries-info/regions.ocbf
How do I open it to view it to double check?

@pnoll1
Copy link
Owner

pnoll1 commented Dec 30, 2022

No clue. Try it in a text editor and if it shows up in gibberish then it’s probably another custom binary format. If that’s the case there should be a program to compile/decompile it somewhere

@pnoll1
Copy link
Owner

pnoll1 commented Mar 24, 2024

Quote reaffirmed by Osmand dev:
Oh I see, so the workaround is something like

osmium extract multiple smaller parts
foreach: MapCreator generate-obf
MapCreator merge-index --address --poi of all the small parts to get one .obf at the end

osmandapp/OsmAnd-tools#687

Looks like this is not only possible, but the way OsmAnd builds the map files themselves.

@pnoll1 pnoll1 added the enhancement New feature or request label Mar 24, 2024
@pnoll1 pnoll1 added this to the 1.13 milestone Mar 24, 2024
@pnoll1 pnoll1 modified the milestones: 1.13, 1.11 Apr 15, 2024
@pnoll1 pnoll1 removed this from the 1.11 milestone Apr 27, 2024
@pnoll1
Copy link
Owner

pnoll1 commented Apr 27, 2024

Blocked by #74, likely means can't be done until #65 is finished

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants