blackrack

[WIP][1.8] Scatterer-atmospheric scattering (v0.0541 - 26/10/2019)

Recommended Posts

I am seeing a few minor issues with the update.

1) On a plain installation (no other visual effects mods), the atmosphere from low orbit in Flight seems much more hazy than it did in the past (like a light/medium fog).  I switched off EVE integration and restarted, but that did not affect it.  (EVE / SVE is not installed; this installation is DX9; no Kopernicus / resizing)

2) From low orbit I see some dark artifacts in the haze now and then that flicker quickly - it looks like part of a texture that's being updated with dark colors, or getting some garbage stuffed into it, at about screen refresh rates.  I have not characterized whether it's tied to specific locations on the planet.

3) The Lens Flare Shader control in the space center does not work as expected:

pl9dDBH5j

Specifically - the lens flare shader button in the space center view appears to toggle extinction on the flare and the halo around the sun, but it does not remove the flare itself.  If I toggle extinction, the ground lighting is updated, but the flare / halo is not.  This behavior is repeatable in my main gameplay installation, as well, which is running in DX11, but I saw other issues (like the ocean appearing black in the space center), so I thought initially it was due to SVE not having a chance to update yet.

If I go to the Flight scene and return to the Space Center, the lens flare is absent if it's been toggled off. The bug is it appears that it isn't removed without switching scenes.

I've put my log and screen shots of all four permutations of [Lens Flare on | off] x [extinction on | off] on DropBox.

Share this post


Link to post
Share on other sites
Posted (edited)

@Galileo I don't know if it was you or someone else who asked about the duna canyons, as I can't find the post now.

Basically scatterer can now handle non-flat scaledSpace models, which is why you get that effect on Duna's canyones. But there is a setting that makes scatterer treat the planet's scaledSpace model as if it was flat, flatScaledSpaceModel = True in the planetsList file.

18 hours ago, Iamsodarncool said:

Looks absolutely wonderful! I can't wait to play with it.

The changelog says you removed godrays. Is there any chance they'll come back? Godrays are one of my favourite effects in scatterer.

Best of luck, friend.

They will be back in time, the current implementation is a bit limited and messes with the other features I wanted to have for this release. It will back when it's improved :)

16 hours ago, KerbalyBoi said:

I just installed Stock Visual Enhancements, Stock Visual Terrain, Environmental Visual Enhancements, Kopernicus, and Scatterer.

I got the clouds from the map view and main menu like I want. However, when I'm at the kerbal space center I get infinite dark clouds like this: video

I took out Scatterer and the problem is fixed; however I get this weird blue effect on the map mode and on the main menu. Does anyone know a way to fix this?

Thanks.

Wait for SVE to update.

14 hours ago, Avera9eJoe said:

Oh, its good they're getting simpler then :). Do you mind if I use your configs as syntax reference when I find the time to update Spectra? Bit swamped in school projects at the moment sadly (Space Shuttle Infographic due on Wednesday that I need to still make).

You can use this repo I created to track changes: https://github.com/LGhassen/ScattererConfig/compare/acbda29a...master

You can see what changed here and use it as a guide.

9 hours ago, kurgut said:

congratz!! awesome work

btw I'm wondering about the eva visor reflections , is the one seen on picture below meant to appear with scatterer,

Or is it enabled by some particular mod?

I got this ingame (with avp, also do the same with SVE) (on ksp 1.6.1, with this release, as previous one) :

thanks!

edit: sry, pretty sure it's texture replacer related thing.. :/

I have noticed this effect and it only happens with TU or TR in certain situations with the sky shader. I will investigate it.

5 hours ago, Walker said:

There are three problems here: 1) missing sphere you mentioned, 2) small, flickering black artifacts (one can be seen on shore, just below missing sphere) - those relatively minor, and 3) scatterer effects on the vehicle. First two dissappear at high altitude, third after scene reload and therefore is more troublesome. What should be done to increase "camera01" far clip value? Is this Sigma Dimensions issue then?

The small black artifacts are probably z-fighting, I will see if I can reduce it.

5 hours ago, MOARdV said:

I am seeing a few minor issues with the update.

1) On a plain installation (no other visual effects mods), the atmosphere from low orbit in Flight seems much more hazy than it did in the past (like a light/medium fog).  I switched off EVE integration and restarted, but that did not affect it.  (EVE / SVE is not installed; this installation is DX9; no Kopernicus / resizing)

2) From low orbit I see some dark artifacts in the haze now and then that flicker quickly - it looks like part of a texture that's being updated with dark colors, or getting some garbage stuffed into it, at about screen refresh rates.  I have not characterized whether it's tied to specific locations on the planet.

3) The Lens Flare Shader control in the space center does not work as expected:

Specifically - the lens flare shader button in the space center view appears to toggle extinction on the flare and the halo around the sun, but it does not remove the flare itself.  If I toggle extinction, the ground lighting is updated, but the flare / halo is not.  This behavior is repeatable in my main gameplay installation, as well, which is running in DX11, but I saw other issues (like the ocean appearing black in the space center), so I thought initially it was due to SVE not having a chance to update yet.

If I go to the Flight scene and return to the Space Center, the lens flare is absent if it's been toggled off. The bug is it appears that it isn't removed without switching scenes.

I've put my log and screen shots of all four permutations of [Lens Flare on | off] x [extinction on | off] on DropBox.

1) Please post screenshots, the scattering config is a bit brighter but other than that I'm not sure what you have.

2) This seems to be z-fighting, I will see if I can reduce or fix it. For info, scatterer no longer uses depth buffer for the main scattering effect, but instead adds the effect to every object in the scene, this allows it to play well with anti-aliasing (as there is no good/correct way for depth buffers to handle anti-aliasing). The second pass scatterer adds still needs to compare it's depth to the depth of the object in the scene, and with limited precision you get those artifacts, the solution on my side would be to trick the depth value reported by the scatterer effect to be a bit smaller.

3) The menu is only really intended to flag changes for when you change scenes, behaviour in the KSC scene itself is undefined and could be anything so just ignore it and change scenes when you changes those settings.

This is not a bug, it's just not a feature.

18 hours ago, Beetlecat said:

Sparktacular!!! my goodness. :D

------

@blackrack

I know it may be gauche to speak of $$ -- but is your paypal supposed to point to a French portal? I don't do the bitcoin thing as yet. -- your humble plea isn't falling on deaf eyes. ;)

I live in France now, so that might be why.

Thank you and thanks to everyone who donated, this is a big help right now for me, thank you all  :)

Edited by blackrack

Share this post


Link to post
Share on other sites
Posted (edited)

Sidenote: I've tried to disable ocean refractions by adding the line into the config, but it seems the ability to do this was removed?

I don't really like the ocean refractions because of this: and would like to turn them off. Has the method of doing this changed or is it no longer possible?

unknown.png

 

Edited by Gameslinx

Share this post


Link to post
Share on other sites
1 hour ago, blackrack said:

This is not a bug, it's just not a feature.

Thank you for clarifying.

1 hour ago, blackrack said:

Please post screenshots, the scattering config is a bit brighter but other than that I'm not sure what you have.

These are from the main menu.  I see the same appearance in flight.

No EVE/SVE:

T9QvCk.jpg

Different install, with EVE/SVE (not updated yet):

QSjCYh.jpg

With EVE, the atmosphere looks clear, without EVE, it looks very hazy.

As a sanity check I installed the previous version of scatterer in the non-EVE version:

acsr8f.jpg

it's actually fairly hazy looking.  To be honest, I don't think I've ever run scatterer without clouds before, so maybe this is Not a Bug as well. Sorry about that.

Share this post


Link to post
Share on other sites
Posted (edited)
1 hour ago, Gameslinx said:

Reporting black artifacts in the upper atmosphere.

The logs, along with the scatterer configs, are here:

https://www.dropbox.com/s/4g2royonif0m5e6/Scatterer-Bug-Report.zip?dl=0

Info:

Video Card: GTX 1080, Resolution: 4k

I am on the latest graphics drivers.

Working on this, for now you can start the game in Dx11 mode and these will be 99% gone.

54 minutes ago, Gameslinx said:

Sidenote: I've tried to disable ocean refractions by adding the line into the config, but it seems the ability to do this was removed?

I don't really like the ocean refractions because of this: and would like to turn them off. Has the method of doing this changed or is it no longer possible?

They can't be disabled anymore, due to technical changes, disabling them will no longer save any performance, so I chose to keep them on, to simplify the code as well. I can try to fade this out however when ascending to get rid of the swirlies/artifacts.

14 minutes ago, MOARdV said:

Thank you for clarifying.

These are from the main menu.  I see the same appearance in flight.

No EVE/SVE:

Different install, with EVE/SVE (not updated yet):

With EVE, the atmosphere looks clear, without EVE, it looks very hazy.

As a sanity check I installed the previous version of scatterer in the non-EVE version:

it's actually fairly hazy looking.  To be honest, I don't think I've ever run scatterer without clouds before, so maybe this is Not a Bug as well. Sorry about that.

That's just how it looks.

I haven't been to space myself (maybe one day) but this is how I see the earth looking whenever I look at untouched apollo pictures

8wxytaua56l11.jpg

21963930856_66e9be4b16_o.jpg

 

Outerra has a fairly realistic atmosphere model and seems to support this as well

Txe0Rjx.jpg

 

Same with google earth when you zoom far enough

02_feed_grid_facebook-001.jpg

Imo most pictures circulating on the internet looking like this must be color-corrected for "maximum visibility", as they do with satellite images the contents clear.

bluemarble.jpg?itok=08uHXinW

 

Edited by blackrack

Share this post


Link to post
Share on other sites

So -- sort of on-topic...

My rig is getting  taxed when installing scatterer + EVE, etc. What's the best bet for helping performance with these different aspects of KSP? I know the general line is that KSP winds up being more CPU intensive than GPU, but does GPU help with things like Scatterer? Is running KSP with Scatterer still going to rely on brute CPU force?

Share this post


Link to post
Share on other sites
8 hours ago, damonvv said:

 Thank you for the update!

Woah... what are those trees from?!

Share this post


Link to post
Share on other sites

Uploading a new version which fixes the z-fighting (flickering squares on the terrain when high in the atmosphere) bug and the bug where the atmosphere is overlayed on ships in orbit.

Enjoy :)

Share this post


Link to post
Share on other sites
Posted (edited)
12 minutes ago, blackrack said:

Uploading a new version which fixes the z-fighting (flickering squares on the terrain when high in the atmosphere) bug and the bug where the atmosphere is overlayed on ships in orbit.

Enjoy :)

Have I said that I love you? Seriously, that's amazing job! Thank you! I may donate something again next week, but... I live in Poland. It's annoying that you'll get less than half of what I send because of the different purchasing power in our countries :( EDIT: I'll think of bitcoins. Never used them before.

Edited by Walker

Share this post


Link to post
Share on other sites
Posted (edited)
1 hour ago, Avera9eJoe said:

Woah... what are those trees from?!

KSC Extended /  Tundra's Space Center

Edited by damonvv

Share this post


Link to post
Share on other sites
Posted (edited)

Sunset/Sunrise tint also happens in orbit =O

 

 

Edited by maccollo

Share this post


Link to post
Share on other sites
Posted (edited)
1 hour ago, Walker said:

Have I said that I love you? Seriously, that's amazing job! Thank you! I may donate something again next week, but... I live in Poland. It's annoying that you'll get less than half of what I send because of the different purchasing power in our countries :( EDIT: I'll think of bitcoins. Never used them before.

Thank you, but it sounds like too much trouble for you, you have already done enough :)

17 minutes ago, maccollo said:

Sunset/Sunrise tint also happens in orbit =O

 

 

Yep, if you look in the album I posted you will see I had one from the mun surface.

Edited by blackrack

Share this post


Link to post
Share on other sites
1 hour ago, blackrack said:

Yep, if you look in the album I posted you will see I had one from the mun surface.

having it happen visible from Kerbin surface or space would still be a separate feature though correct? I'm still on 1.5.1 so haven't checked out the new version yet myself

Share this post


Link to post
Share on other sites
Posted (edited)

Wait a second... Maccollo?! @maccollo I haven't see you in years! :D your Venus mission is one of my all-time favorite KSP videos, up there with Katateochi's constellation mission. Your old videos are part of what got me so interested in building myself. It's good to see you man :)

Edited by Avera9eJoe

Share this post


Link to post
Share on other sites
5 hours ago, Drew Kerman said:

having it happen visible from Kerbin surface or space would still be a separate feature though correct? I'm still on 1.5.1 so haven't checked out the new version yet myself

Nope, same feature, as long as the atmosphere is loaded, you could technically see it from anywhere if you get the alignment right.

Share this post


Link to post
Share on other sites
Posted (edited)

Hey, i'm getting a bug where occasionally the scene will turn completely white. This happens in space as well as on the ground. When this happened initially i was orbiting a moon. The map view is unaffected.

https://www.dropbox.com/s/48recmcmmfran1v/Scatterer-Bug-Report-2.zip?dl=0

dR2UipR.png

Bug occurs here:

[LOG 10:40:18.576] DragCubeSystem: Rendering procedural drag for mk2LanderCabin.v2
[EXC 10:40:18.576] NullReferenceException: Object reference not set to an instance of an object
	scatterer.DepthToDistanceCommandBuffer..ctor ()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[EXC 10:40:18.576] NullReferenceException: Object reference not set to an instance of an object
	scatterer.DepthToDistanceCommandBuffer..ctor ()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[EXC 10:40:18.577] NullReferenceException
	UnityEngine.Component.GetComponent[Camera] ()
	scatterer.ShadowRemoveFadeCommandBuffer..ctor ()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[LOG 10:40:18.585] [Scatterer] Removing DepthToDistanceCommandBuffer from Camera 01
[EXC 10:40:18.585] NullReferenceException: GetRef
	scatterer.DepthToDistanceCommandBuffer.OnDestroy ()
	UnityEngine.Object:DestroyImmediate(Object)
	FlightCamera:Awake()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[LOG 10:40:18.585] [Scatterer] Removing DepthToDistanceCommandBuffer from Camera 00
[EXC 10:40:18.586] NullReferenceException: GetRef
	scatterer.DepthToDistanceCommandBuffer.OnDestroy ()
	UnityEngine.Object:DestroyImmediate(Object)
	FlightCamera:Awake()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[EXC 10:40:18.586] NullReferenceException: Object reference not set to an instance of an object
	scatterer.ShadowRemoveFadeCommandBuffer.OnDestroy ()
	UnityEngine.Object:DestroyImmediate(Object)
	FlightCamera:Awake()
	UnityEngine.Object:Instantiate(Part, Vector3, Quaternion)
	DragCubeSystem:RenderProceduralDragCube(Part)
	DragCubeList:SetDragWeights_Procedural()
	DragCubeList:SetDragWeights()
	FlightIntegrator:DragCubeSetupAndPartAeroStats(Vessel)
	FlightIntegrator:FixedUpdate()
	ModularFI.ModularFlightIntegrator:TimedFixedUpdate()
	TimingFI:FixedUpdate()
[WRN 10:40:18.675] HighlightingSystem : Edge Highlighting requires AA to work!

How to reproduce: Quicksave, then load a quicksave.

Edited by Gameslinx

Share this post


Link to post
Share on other sites
1 hour ago, Gameslinx said:

Hey, i'm getting a bug where occasionally the scene will turn completely white. This happens in space as well as on the ground. When this happened initially i was orbiting a moon. The map view is unaffected.

https://www.dropbox.com/s/48recmcmmfran1v/Scatterer-Bug-Report-2.zip?dl=0

How to reproduce: Quicksave, then load a quicksave.

I quicksaved and loaded many times, in different situations but could not reproduce it.

I'm guessing what the cause may be, based on the log, so try this dll: https://mega.nz/#!DARg1QIL!wIk8mWRNc0vIkixjNYy4K9YR4R2rTMjsYcEO324o3P8

If it doesn't work, I would suggest you try to narrow it down, lowering the number of mods, and trying to identify a situation in which it is easily reproducible.

Share this post


Link to post
Share on other sites
2 hours ago, blackrack said:

I quicksaved and loaded many times, in different situations but could not reproduce it.

I'm guessing what the cause may be, based on the log, so try this dll: https://mega.nz/#!DARg1QIL!wIk8mWRNc0vIkixjNYy4K9YR4R2rTMjsYcEO324o3P8

If it doesn't work, I would suggest you try to narrow it down, lowering the number of mods, and trying to identify a situation in which it is easily reproducible.

I'll give the DLL a go when I get home and I'll be sure to let you know of what happens, and if it happens I'll try again with a stock install and try to reproduce the bug again

Share this post


Link to post
Share on other sites
Posted (edited)

Hello there. Wery happy about the update, but it seems i have some troubles here.

https://imgur.com/a/fLVgwG3

Please, look at the water. The ocean looks weird, when you try to launch on sunrise. It strikes more with the altitude, higher - more visible. And finaly on certain altitude it just disappears. I have only Scatterer and Distant Object Enhancement installed.

 

Edited by G_Force080491

Share this post


Link to post
Share on other sites
2 hours ago, G_Force080491 said:

Hello there. Wery happy about the update, but it seems i have some troubles here.

https://imgur.com/a/fLVgwG3

Please, look at the water. The ocean looks weird, when you try to launch on sunrise. It strikes more with the altitude, higher - more visible. And finaly on certain altitude it just disappears. I have only Scatterer and Distant Object Enhancement installed.

 

This is the ocean refraction bug I mentioned above. We used to be able to turn it off but now we can't and it looks quite bad from above.

Share this post


Link to post
Share on other sites
Posted (edited)

@blackrack Usually the bug happens every 20 minutes or so playing, but using your new DLL in around 2 hours of playing I have yet to see it happen and I've done a lot of quicksaving/quickloading. I'll let you know if it does happen (I bet it will just after i send this reply, lol) but for now thank you very much for the bug fix!

 

Edit: The flashing ocean artifacts are back :( 

Edited by Gameslinx

Share this post


Link to post
Share on other sites
12 minutes ago, Gameslinx said:

@blackrack Usually the bug happens every 20 minutes or so playing, but using your new DLL in around 2 hours of playing I have yet to see it happen and I've done a lot of quicksaving/quickloading. I'll let you know if it does happen (I bet it will just after i send this reply, lol) but for now thank you very much for the bug fix!

Edit: The flashing ocean artifacts are back :( 

They are back with the new .dll? Or you just noticed them in a new situation you didn't check was fixed before?

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.