Jump to content
  • Advertisement
  • entries
    232
  • comments
    1463
  • views
    961383

Terrain integration, step 2

Sign in to follow this  
Ysaneya

322 views

Been a while since i last posted some screenshots:





Things are becoming messy, to say the least. It looks nice and clean in the screenies, but i still have to face a high amount of bugs or problems. I've recently been working on matching the lighting with the sun direction as seen through the atmosphere (yeah, it was incorrect before!), but i think i still have a bug somewhere.. and it's not easy to fix, since the sun has to be transformed by the whole objects hierarchy, which means lots of object-to-world and world-to-object space matrices calculations.

Edges are still visible between adjcent terrain patches, sometimes it's very ugly, sometimes almost unnoticeable. In order to fix it, i'll have to replicate the normals on the bounaries between adjacent patches, but i've yet to write the code.

Another problem is with the heightfield. In the transition between my previous tech demo (which was a standard, flat terrain) to the current one (which is curved on the planet's surface), i feel the heightfield has lots some style. Hard to explain, but now, everything looks very repetitive and similar, at any place on the planet. It's probably just a matter of finding good parameters for the noise functions, but again another thing to fix.

I've switched the high frequencies noise generation to diamond-square - that is much, much faster than 3D Perlin noise, by an order of magnitude at least, and it's important when the camera is near the ground level, since if you're moving quickly, a lot of terrain patches have to be regenerated ( and at that altitude the noise is at high frequencies ). Unfortunately, the same scale is used everywhere on the planet, so it's impossible to mix flat areas noise (for valleys) and mountainous areas noise. Another point in my TODO list.
Sign in to follow this  


4 Comments


Recommended Comments


Fantastic. Funny but the top one looks a bit like Canada the last time I flew over it on a trip from the UK.

Share this comment


Link to comment
The depth haze in the first image amazes me. The transition from terrain to atmosphere is very smooth.
In my own project, this was not so good.
Is this a by-product of the exponential scaling of the colors or did you apply some special hack to achieve this?

Share this comment


Link to comment
Quote:
Is this a by-product of the exponential scaling of the colors or did you apply some special hack to achieve this?


There is only one "hack": i'm using two different sets of parameters, one for ground level, one for space, and interpolate between the two depending on the camera altitude. In the future i might even add a third set of parameters, for sunsets (since the colors subtely different than what i'd like to have at sunset).

To determine these parameters, well, no miracle. I have assigned a key to each parameter, and i can increase/decrease its value in real-time. So it's just a matter of playing with all the parameters until you get something you are happy with..

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!