Oolite Bulletins

For information and discussion about Oolite.
It is currently Fri Sep 22, 2017 12:51 am

All times are UTC




Post new topic  Reply to topic  [ 20 posts ]  Go to page Previous 1 2
Author Message
PostPosted: Sat Sep 09, 2017 11:11 am 
Offline
---- E L I T E ----
---- E L I T E ----

Joined: Sun Jul 21, 2013 12:26 pm
Posts: 471
Quote:
Quote:
Wasn't there something like a shady planet branch or something? Wasn't it supposed to do something like that? What happened to that?
It went stale long time ago and there have been many changes in the planet drawing code and shaders since then, so it may not be such a simple job bringing it up to date.

In any case, I think that shaders would be the way to go about implementing this request. I doubt that flashers or other look-alike effects would be able to cut it.
Almost there (temporary hosting):

Image

The relief in 1.85 with perlin textures is a little bit too strong in my opinion, so I was trying to make it more "flat". I changed the rescale factor from 127.5 to 63.5 at lines 491-493 in OOPlanetTextureGenerator.m. N

However, there are side effects that are more or less welcome (~3MB).

Obviously I don't know what I'm doing. I believe I accidentally flipped the normals for the oceans. Someone more knowledgeable than me about that stuff can probably put it to good use.


Top
   
PostPosted: Sun Sep 10, 2017 6:26 pm 
Offline
---- E L I T E ----
---- E L I T E ----

Joined: Sun Jul 21, 2013 12:26 pm
Posts: 471
Actually my first goal was to try to mix the old generator and the new generator to obtain landscape features. But it came to me that there may be an easier and cheaper way: use the clouds texture.

Something like: take the clouds texture, keep only the highest values of alpha, and mix it with the ground texture in reverse pixel order (so that the trick isn't too obvious). High alpha values could be use to introduce terrain features with a different color (maybe swap components of the ground color?), low values could be used for city lights. Can someone explain what I've accidentally discovered to me?


Top
   
PostPosted: Tue Sep 19, 2017 10:59 am 
Offline
---- E L I T E ----
---- E L I T E ----

Joined: Sun Jul 21, 2013 12:26 pm
Posts: 471
After some more reading, trial and error (temp hosting):

Image

This is the dark side of a planet near the dawn line; one can see a bit of the lit part in the bottom right corner. The bright dot on the left is a star, the other isolated points are space dust.

I targeted the coastlines to make tests more easy, so it looks a bit ugly and silly (actually on this picture the criteria was still including water bodies). As far as I understand it, I indeed flipped the depth coordinate of the normal vectors (Z in [0..128] instead of [128..255]).

The downside is that the brighter the point is on the dark side, the darker it will appear on the lit side. So it looks terrible especially on the coastlines which are normally pale, but I think it's still usable for cities which can be dark patches. Maybe it will be possible to mitigate this by picking a bright color for them.


Top
   
PostPosted: Thu Sep 21, 2017 3:15 pm 
Offline
---- E L I T E ----
---- E L I T E ----

Joined: Sun Jul 21, 2013 12:26 pm
Posts: 471
I give up. The glow is too faint on the dark side and it looks horrible on the light side no matter what, and it doesn't look like cities anyway.

I guess we will have to wait for shader gurus to pick it up. I think the way to go would be something like:
1. Create predefined city patterns textures with associated shaders,
2. Pick a bunch of them pseudo-randomly and superpose them,
3. Apply the texture generator on top of that map to get relief, oceans, specular lighting etc.

Or maybe run the texture generator first then apply the city textures on top of it.


Top
   
PostPosted: Thu Sep 21, 2017 11:55 pm 
Offline
Commodore
Commodore
User avatar

Joined: Tue Jan 21, 2014 10:37 pm
Posts: 1707
Location: [p]laying [h]ard and [k]icking [b]utt somewhere in G7...
Sometimes things work out, and sometimes they don't, but we won't know until we try. Thanks for your work on this, even though it didn't work out the way you wanted. Well done.

Shader gurus .. over to you!

_________________
My OXP's


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 20 posts ]  Go to page Previous 1 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 9 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Limited