blackrack

[WIP][1.10.x] Scatterer-atmospheric scattering (v0.0632 - 26/08/2020)

Recommended Posts

Usually forced aniso causes it, if you no longer have aniso forced from the drivers try putting KSP graphics in "fastest" mode, that usually fixes it. In the previous versions I used to disable aniso from within the mod itself but after I switched to a new mesh I found it wasn't necessary anymore. In this case it might be stilla problem with openGL(full of problems btw), give it a try with dx9. If not I could just put in a "toggle aniso" switch for people who get the bug.

I'll try it with d3d11 but unfortunately d3d9 isn't really an option :\

[edit] D3D11 results

Javascript is disabled. View full album

Results good (no blue/red lines etc) until orbit then some oddities at height

Share this post


Link to post
Share on other sites
I'll try it with d3d11 but unfortunately d3d9 isn't really an option :\

[edit] D3D11 results

http://imgur.com/a/9Uhog

Results good (no blue/red lines etc) until orbit then some oddities at height

Yeah that's caused by the PQS and the modified camera plane thing I just wanted to try out, disregard those. Why is d3d9 not an option though? It's best for this mod.

I keep getting a bug with this where the KSC at menu screen is zoomed in on the SPH and I can't click anything. Would you know anything about this Blackrack? I know it's caused by Scatterer because it disappears when I delete it.

EDIT: It's probably actually a comparability with another mod. Disregard. :P

No idea, really.

Share this post


Link to post
Share on other sites
Yeah that's caused by the PQS and the modified camera plane thing I just wanted to try out, disregard those. Why is d3d9 not an option though? It's best for this mod.

Cool, I had no other issue to report apart from that.

D3DX9 does wierd things with texture mirroring (dx9 unity bug) that D3D11 mostly doesn't, short story D3D9 runs KSP out of memory and crashes and D3D11 doesnt.

Share this post


Link to post
Share on other sites

Update! The bug is a compatibility issue with KerbCam. Meaning I won't be able to use this mod for cinematics unless it's fixed ;.;.

Share this post


Link to post
Share on other sites
Cool, I had no other issue to report apart from that.

D3DX9 does wierd things with texture mirroring (dx9 unity bug) that D3D11 mostly doesn't, short story D3D9 runs KSP out of memory and crashes and D3D11 doesnt.

In this case just use loadOnDemand like I do, it's amazing for RAM usage and cuts your load time by 70%.

Update! The bug is a compatibility issue with KerbCam. Meaning I won't be able to use this mod for cinematics unless it's fixed ;.;.

Great job, I'll look into it as soon as I can.

Share this post


Link to post
Share on other sites
*snip*

- - - Updated - - -

Oh dear god, it works

*snip*

Now I just have to fix a few issues.

The best thing I can tell you guys right now is that the framerate hit seems minimal.

No! That's too pretty!

You're doing amazing work here blackrack. Here's hoping to co-operative coding for you!

Share this post


Link to post
Share on other sites

Oh! I didn't have time to post this last night. I made a speedy mod preview!

1.0 here we come!

Share this post


Link to post
Share on other sites
I keep getting a bug with this where the KSC at menu screen is zoomed in on the SPH and I can't click anything. Would you know anything about this Blackrack? I know it's caused by Scatterer because it disappears when I delete it.

I have had this bug in a stock game. For me it shows up if I switch applications while the Space Center scene is loading. If I keep KSP open the bug does not occur. (Running OSX here.)

Share this post


Link to post
Share on other sites
I keep getting a bug with this where the KSC at menu screen is zoomed in on the SPH and I can't click anything. Would you know anything about this Blackrack? I know it's caused by Scatterer because it disappears when I delete it.

You should reproduce the problem again. Then get your output_log.txt file (NOT ksp.log)

put it up for download (zip it up if necessary)

post the link here

Share this post


Link to post
Share on other sites
Platform and renderer? Normally the sky should go red and the game would hang for two frames while reloading the tables after you alt-tab out or hit alt-Enter but then recover and continue as normal.

- - - Updated - - -

Oh dear god, it works

http://i.imgur.com/cN5XcuX.jpg

http://i.imgur.com/lqWDNfN.jpg

http://i.imgur.com/eWji25x.jpg

Now I just have to fix a few issues.

The best thing I can tell you guys right now is that the framerate hit seems minimal.

Yeah! Let me know if you want any help with this one. I altered the terrain shader to shade the ocean based on depth, and if you could make the ocean slightly transparent, it would be a great way to add depth.

Also: You can't really use a post-processing mechanism with the ocean. At some point, craft will intersect the water, and purely post-processing can't account for it. You have to use the existing geometry unfortunately.

Share this post


Link to post
Share on other sites
Wau that water. How you did this ? That water is fantastic. Hope Proot will have something simmilar in his mod.

Thanks, but my stuff is completely dependant on mods like this, EVE (by Rbray89) or TR (by Shaw), RSS (by NathanKell) and so on...

I'm just an artist, an esthete, obsessed by the detail.

So none of my achievements is even possible without people like blackrack or all them.

All praise to the "essential mods" creators. ;)

Share this post


Link to post
Share on other sites
Yeah! Let me know if you want any help with this one. I altered the terrain shader to shade the ocean based on depth, and if you could make the ocean slightly transparent, it would be a great way to add depth.

Also: You can't really use a post-processing mechanism with the ocean. At some point, craft will intersect the water, and purely post-processing can't account for it. You have to use the existing geometry unfortunately.

Hi rbray, this water is based on the projected grid method so it uses a bunch of meshes and not postprocessing. It will have it's own reflections and inscattering in it's shader and won't rely on postprocessing for these too. In order for the postprocessing used for everything else not to conflict with it, there's a very simple trick, the postprocessing shader already reconstructs the world position of every point in the scene by using the depth buffer and the camera's view frustum, world position and orientation. This way I could add a condition in the postprocessing shader to not apply to anything that is below sea level, so that geometry that is underwater won't cause any postprocessing to draw over the water, and I can just disable the stock ocean altogether or just cover it up and prevent it from writing to the depth buffer. (Edited: this could also work for clouds, but only if said clouds are guaranteed to be higher than the highest mountain on that planet and have no transparency, so it's more or less useless).

This is what I have in mind right now, I haven't put any work in it today because I haven't had the time so water is still in the state that you see in these images. Making the ocean transparent should be easy but I'm not sure I understand what you meant about shading the ocean based on depth. Also, this will use it's own meshes and not rely on the existing ocean geometry.

Edited by blackrack

Share this post


Link to post
Share on other sites
Hi rbray, this water is based on the projected grid method so it uses a bunch of meshes and not postprocessing. It will have it's own reflections and inscattering in it's shader and won't rely on postprocessing for these too. In order for the postprocessing used for everything else not to conflict with it, there's a very simple trick, the postprocessing shader already reconstructs the world position of every point in the scene by using the depth buffer and the camera's view frustum, world position and orientation. This way I could add a condition in the postprocessing shader to not apply to anything that is below sea level, so that geometry that is underwater won't cause any postprocessing to draw over the water, and I can just disable the stock ocean altogether or just cover it up and prevent it from writing to the depth buffer. (Edited: this could also work for clouds, but only if said clouds are guaranteed to be higher than the highest mountain on that planet and have no transparency, so it's more or less useless).

This is what I have in mind right now, I haven't put any work in it today because I haven't had the time so water is still in the state that you see in these images. Making the ocean transparent should be easy but I'm not sure I understand what you meant about shading the ocean based on depth. Also, this will use it's own meshes and not rely on the existing ocean geometry.

I left the ocean semi-transparent, and I shade the terrain (ocean floor) based on the "depth" (distance from the intersecting ocean sphere to the terrain). It works pretty well to simulate depth. Pretty much what stock does but a little better.

Share this post


Link to post
Share on other sites
I left the ocean semi-transparent, and I shade the terrain (ocean floor) based on the "depth" (distance from the intersecting ocean sphere to the terrain). It works pretty well to simulate depth. Pretty much what stock does but a little better.

Got it, somehow I thought you modified the ocean's transparencey based on depth. This makes more sense.

Oh! I didn't have time to post this last night. I made a speedy mod preview!

1.0 here we come!

I like your opening shot, I never tried to watch the sunrise from over a mountain...

no chance to port this to linux/os x?

It already works on osx/linux it's just buggier and slower for now...

No! That's too pretty!

You're doing amazing work here blackrack. Here's hoping to co-operative coding for you!

- - - Updated - - -

Wau that water. How you did this ? That water is fantastic. Hope Proot will have something simmilar in his mod.

Thanks, but my stuff is completely dependant on mods like this, EVE (by Rbray89) or TR (by Shaw), RSS (by NathanKell) and so on...

I'm just an artist, an esthete, obsessed by the detail.

So none of my achievements is even possible without people like blackrack or all them.

All praise to the "essential mods" creators. ;)

Wait until it works with everyhting in the game you guys, plus it reflects the sky and the sun, has adjustable color, wind speed, waves and foam so in theory it should be possible to adjust it to make convincing mercury oceans on EVE or something like that.

Share this post


Link to post
Share on other sites
Wait until it works with everyhting in the game you guys, plus it reflects the sky and the sun, has adjustable color, wind speed, waves and foam so in theory it should be possible to adjust it to make convincing mercury oceans on EVE or something like that.

I made this with wip-EVE...

Javascript is disabled. View full album
I wish so much the compatibility... (no pressures) ;)

Share this post


Link to post
Share on other sites

This looks amazing. I just saw the pictures and thought insta download...exept right now I am on my phone. I will get this tomorrow though.

Share this post


Link to post
Share on other sites
I made this with wip-EVE... http://imgur.com/a/6X04q I wish so much the compatibility... (no pressures) ;)

Rbray explained a technique to me that could make scatterer compatible with EVE, let me just finish up a few things first.

Any update for 1.0? Status? Keep up the good work! :P

I haven't even booted up 1.0 yet, I haven't had any free time so you guys just test it out and report back.

Share this post


Link to post
Share on other sites

I'm justt wanted to pop by to say how amazing this stuff is and I can't wait to try it out.I have been absent from playing KSP for a while but now with 1.0 I shall return to it again. And this mod is a absolut must for me to play with. If it would become compatible with EVE , it would just be even more aweseome. For now just have my +rep

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.