Page 1 of 3

Eroded and Enhanced Terrain

Posted: Wed Jan 06, 2021 12:35 am
by Freak2121
Nexus link.

Screenshots:
Spoiler!
Image

Image

Image

Image
Hello! It has always been on my mind (since 2011 at least) that a remake/upgrade for Daggerfall would look stunning and beautiful if the primitive heightmap were replaced with a much more detailed and realistic one instead.

For years I toyed around with lots of different software, different methods, different ideas, etc trying to make a good heightmap but I never had the opportunity to test it out. That is, until recently when chtujo contacted me and told me Daggerfall Unity actually draws its height information from WOODS.WLD, rather than a simple heightmap image. I still had FiryWoods around, a tool that lets you edit WOODS.WLD, although chtujo made his own tool which I haven't had the chance to try yet. I also had World Machine installed, as well as my old files for editing the heightmaps. So everything was in place to make this happen. :)

The process is detailed in short on the Nexus page's description.

The terrain has very natural transitions between areas, is decently interesting without being cartoony, and is fairly faithful to the original. It is also tweaked for and intended to be used with Nystul's Distant Terrain mod. There are some issues, however.

Issues:
1. The terrain is very noisy/bumpy pretty much everywhere. It just doesn't look good.
2. There's a lot of missing detail. I've replaced the noise map with a high quality version of the heightmap, however, I have no idea how to make it actually reflect on the terrain as extra details. There's a pretty significant difference in quality between the heightmap (800m/px) and the noise map (160m/px) and a lot of details such as river valleys are lost.
3. There are no more lakes. I'm sorry for killing them off. :lol: Daggerfall and Daggerfall Unity use sea-level heights to form lakes, water doesn't form on any other height. If I kept it as is, there would be a bunch of massive pits all over the landscape and not only would it look ugly, it would throw the erosion and river simulations off. So I just leveled them with their surrounding terrain.


Github.

I hope this interests some of you, I'd love some feedback. If not, at least there's some pretty pictures. :D

Many thanks to chtujo.

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Wed Jan 06, 2021 1:31 am
by l3lessed
This is great. I love it. Thanks for the work. Man, would it be nice to have water at differing heights.

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Thu Jan 07, 2021 8:09 pm
by Nystul
this is good work - looking very interesting.
we get more and more alternatives for terrain samplers, and the quality increases how it seems ;)

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Thu Jan 07, 2021 8:53 pm
by BadLuckBurt
This is pretty damn awesome, I need to dive back into the rabbit hole that is my terrain sampler.

So you have only modified the 5000x2500 heightmap but still use the default terrain sampler, right? The bumpyness is being caused by the noise settings in the sampler and can be tweaked with a custom sampler. I will experiment with my own sampler and this mod to see what happens. I have pretty insane mountains with my sampler, it'll be interesting to see what it makes of this version of WOODS.WLD

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Fri Jan 08, 2021 10:13 am
by Freak2121
I've made a small update. These are the following changes:
Spoiler!
Fixed locations sticking out into the sea by adding flat beaches to select areas. There should be next to none of this anywhere on the map now.

Image

Fixed the inlet by Privateer's Hold actually becoming a lake.

Image

Slightly lowered mountain heights.

Image
So you have only modified the 5000x2500 heightmap but still use the default terrain sampler, right? The bumpyness is being caused by the noise settings in the sampler and can be tweaked with a custom sampler. I will experiment with my own sampler and this mod to see what happens.
That's right. I'll be very eager to know how it goes.

By the way, if any of you can make use of a river map, here it is for this heightmap.

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Sat Jan 16, 2021 6:35 am
by Freak2121
After playing for about a week with no apparent issues at all, I've uploaded the file to Nexus and decided to call it version 1.0.

This version has a small change -- Chtujo told me that Daggerfall unity only takes a 3x3 portion of the 5x5 noise grid per map pixel into account and provided me with a tool to correctly replace the noise map with a 3000x1500 counterpart. It should be just slightly more accurate and nicer to look at now.

Re: Handcrafted + Eroded Terrain Heightmap

Posted: Sat Oct 16, 2021 12:14 pm
by King of Worms
Hi, I use Interesting Eroded Terrain (which I think is the most advanced of your terrains, right) and it does not work with DFU 0.13+ . Are you aware of that? Any plans to re-release the mod? Thank you :)

Re: Eroded and Enhanced Terrain

Posted: Sun Oct 17, 2021 10:09 pm
by Freak2121
Hey, King of Worms! Yes, I am aware. The terrain generation seems to be working, but locations always generate at sea level. Unfortunately I am not a programmer, so even after hours of looking at the scripts and files, I have no idea what the issue could possibly be or where I could even begin in fixing it. Interesting Eroded Terrain will be dead until someone who can actually program decides to fix it. :(

Re: Eroded and Enhanced Terrain

Posted: Sun Oct 17, 2021 11:20 pm
by Interkarma
Hey Freak2121. :)

I'll try to work out what's happening and get back to you in a few days. This is an odd one as there have been no changes in 0.13 directly related to terrain generation or height sampling. I'm not sure yet what causes this problem for your mod. No promises, but I'll do my best to track it down and give you a solution.

Re: Eroded and Enhanced Terrain

Posted: Mon Oct 18, 2021 1:45 am
by Interkarma
I've identified root cause. It's down to Gamma > Linear colourspace change causing custom heightmap textures to be processed differently. Simply switching back to Gamma colourspace restores mod functionality. This isn't a solution yet, but it's a good starting point to understanding problem.

In linear colourspace, non-colour textures containing height or other data should have "sRGB" box unticked or use Single Channel import format depending on usage. Shaders also need to process input texture appropriately.

I don't know enough about mod and its compute shaders to suggest exactly what changes are needed to fix. I tried playing around with import settings of heightmap textures in Assets/Maps, but wasn't able to find a combination that fixed everything, just yielded different broken results.

But the core issue is gamma > linear difference on input heightmaps. Basically what's happening is the texture/shader is returning wrong heightmap values back to game in different colourspace using texture-based heightmaps.

I hope that helps you get started with a fix! I can loop back if you're still hitting a brick wall. I will do what I can, but must admit your compute shaders are a little beyond me, so I may not be much help. :)