-
-
Notifications
You must be signed in to change notification settings - Fork 379
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
[DISCUSSION] Thought process on how to add elevation #66
Comments
Hi there! That's amazing, thank you for reaching out! Really cool to get feedback and input from people who actually know what they're doing. ;) I had a pretty similar thought process. I already played around in the "old" Python version with implementing some sort of elevation, but I failed with getting a data source which is:
In regards of the implementation, like you mentioned we'd have to map the elevation data to the exact same area as the elements using the bbox and the scaling factor. I'm pretty sure this is just some maybe annoying fine tuning work, but sounds doable. For the next step, my approach would have been to use the position as an index when placing blocks to retrieve the according elevation at that exact coordinate. But this assumes that we have a data source which fits our criterias. I can imagine some pretty weird structures if there's e.g. a sudden peak in elevation due to an unfiltered tree height, if you know what I mean. I will use your Issue as a discussion thread for further updates on this topic. Thanks for the DEM hint, I will look into this further. Curious to hear your thoughts on this! :) |
Thanks for the detailed and supportive reply!! In terms of free APIs we could potentially utilize: But I think users would need to sign up with an API key and we'd have to parameterize that as a command line argument. Open Topography
params = {
"demtype": dem_type,
"south": south,
"north": north,
"west": west,
"east": east,
"outputFormat": "GTiff"
} Not sure if there is another free solution without API keys, but I'll keep looking around! |
Another issue is the world height limit. I could stand in the ocean and end up 960 meters above sea level with 8 hours of walking where I used to live. |
Hi, another GISer here :) Very nice work and I'm thinking about this same topic when exploring the generated world. This open-sourced elevation API project open-elevation could be a good candidate but it's not active any more unfortunately. Some of its forks, e.g. this one according to this ticket, are well maintained. There is a free public API at https://open-elevation.com/ but the availability could not be guaranteed. The self-hosted service is encouraged and easy to setup. Since I guess the elevation support in Arnis will be optional, to have a simple script launching open-elevation locally when required could be a feasible solution. |
Hey on the note of height limit, in the latest releases of mc in world data packs you can set the height limit to a max of 2000+ so this part shouldn’t be too much of an issue |
Open Elevation is, afaik, just a wrapper around the SRTM dataset. We could use this dataset directly if we wanted, without requiring the wrapper, however it's captured from satellites so I'd be worried about that messing it up. I suppose it would be relatively easy to check the dataset to see if this is an issue or not. |
Some years ago, a modder named Gegy made an earth mod with elevation called Terrarium. It can be found here on github, perhaps it might give you some tips |
https://www.gebco.net/data_and_products/gridded_bathymetry_data/ "GEBCO’s current gridded bathymetric data set, the GEBCO_2024 Grid, is a global terrain model for ocean and land, providing elevation data, in meters, on a 15 arc-second interval grid. It is accompanied by a Type Identifier (TID) Grid that gives information on the types of source data that the GEBCO_2024 Grid is based on. " @louis-e LMK if you need any testing, I'm on MacOS. |
You can allways cap it, or restrict the world height by injecting a datapack:
|
Another earth to Minecraft tool called Chunkmapper by whamtet has tackled the elevation issue by simply only generating maps at 1:30 scale so that Mount Everest would within the height limit. Of course, he didn't use the earth data for real life buildings because they'd be way too small, so he had Chunkmapper generate rows and columns of random buildings for cities. Oh and another thing about that tool is that it's meant to keep on running so that it would continue to generate more chunks based on earth data as you move around in game. Now suppose we didn't worry too much about the higher elevations on earth and just focus on having the tallest building in the world to scale down to fit within minecraft's height limit, we could have the option to have earth generated at 1:3 scale (33.33%). |
@scd31 How did you make the landscape? |
scd31 provided us his amazing work which we are now continuing to develop in the elevation-wip branch. I already resolved the merge conflicts to the current main code base. The next thing we have to do is adapting all element processors (src/element_processing/*) to the new feature and then replace the current sine wave implementation with an actual elevation data parser. |
I have tried out f50e108 and I know it is not finished, but its cool seeing the progress being made. Right now it looks like basic sin wave and there are random circular holes, but I cant wait. |
@louis-e @albertkun I did some research and had AI just format it but there are some good sources below Suitable Heightmap Data Sources for Arnis
Candidate Data Sources:
|
thank you @carterlasalle !! so exciting to see this progress!!! let me know if there's any need for support on geospatial processing of the data in the elevation-wip branch!! |
Looks beautiful!!! |
Sorry for the delay, catching up with all the progress on main requires more time than expected haha! Also vacation is over since last week and I need to work again. I'm freezing the main branch for a few days until the terrain is fully implemented, then I'll get back to all the pull requests! |
Wait, never mind. It is correct. @louis-e I did not realize that OSM updated that quickly. My house and the entire neighborhood burned down a couple of weeks ago in the massive Los Angeles fires. Disregard the above! |
Oh no, I'm so sorry for your loss. Didn't know the building data was already removed on OSM... @carterlasalle |
this is amazing!! i'll probably get around to testing it next week! i fled the fires from Los Angeles and am visiting my family at the moment :( but excited to test it when i get home!! |
okay! did some testing and maybe this is more of a problem with the OSM data (because it happens in other platforms too using 3d buildings and OSM data), but some buildings happen to cut the terrain out instead of being placed on top of it. i believe this is related to this #325 (comment).. Example1 .5 scaleExample 21.20 scaleI think what we usually try to do to solve this is to extrude the foundation of the building(1) so that it is level where (2) is. Hope that makes sense! |
Hello! GIS Specialist here! Great work on this project!!
I Just wanted to start a discussion on how to achieve elevation with the OpenStreetMap (OSM) data set in to Arnis, since I see it is on the todo list!
I believe the most suitable format would have to be Digital Elevation Model (DEM) data or some other raster input.
I'd be happy to help out with implementing this, but wanted to see what the current thought process for achieving this would be! I haven't coded anything Minecraft related before, but I work extensively with GIS data and enjoy coding in Rust!
Additional thoughts
The text was updated successfully, but these errors were encountered: