Jump to content

[WIP][1.9.x-1.12.x] Scatterer-atmospheric scattering (0.0838 - 14/08/2022) Scattering improvements, in-game atmo generation and multi-sun support


blackrack

Recommended Posts

11 hours ago, blackrack said:

The weird thing is, shaders in assetbundles are not even compiled, I believe the specific variant for the platform is compiled at runtime, so it seems really weird to me that we'd need to make separate bundles for each platform.

Are you sure they aren't? The asset bundles for each platform are very different sizes.

I just use the default Unity settings for projects, which is only D3D9 and D3D11 (so --force-opengl might not work). MacOSX is GLCore then GL2 (i.e. reverse order to what you showed). Note that I had to use Unity 5.2.4 first, to generate the assetbundle XML for KSP, but then actually build the assetbundle in Unity 5.4.0 (the one KSP uses).

I didn't deliberately change anything, but I'm no expert on those shaders, so if something broke, I'd probably not realize it.

Edited by Waz
Link to comment
Share on other sites

7 hours ago, Waz said:

Are you sure they aren't? The asset bundles for each platform are very different sizes.

I just use the default Unity settings for projects, whatever that is. Note that I had to use Unity 5.2.4 first, to generate the assetbundle XML for KSP, but then actually build the assetbundle in Unity 5.4.0 (the one KSP uses).

I didn't deliberately change anything, but I'm no expert on those shaders, so if something broke, I'd probably not realize it.

I would think they aren't because usually shaders with lots of variants and multi-compile directives take a while to compile but I noticed building the asset bundles is really fast and the filesize is always low even if I don't use the compress option.

EVE has even more shader combinations so usually EVE shaders take a while to compile and are heavy in filesize. How long do EVE asset bundles take to build for you?

In any case what's the assetbundle XML and why do we need to generate it?

And would you know anything about the render order issue above?

Edited:

7 hours ago, Waz said:

I didn't deliberately change anything, but I'm no expert on those shaders, so if something broke, I'd probably not realize it.

I checked your commits and it doesn't seem like there is anything related to it, so it's probably something that changed in unity.

Also, can be seen through the volume particles and the 2d clouds (both without scatterer):

vK2IkEW.jpg

 

Edited:

I fixe the issue and made a pull request, for everyone who wants to grab fixed dlls go here: http://forum.kerbalspaceprogram.com/index.php?/topic/51142-1121-1-2-may-13-2016-environmentalvisualenhancements/&do=findComment&comment=2774007

 

Edited by blackrack
Link to comment
Share on other sites

Hello!

IT'S SO BEAUTIFUL.

screenshot7%20(3).png

 

Thank-you! The only problem I seem to have is that dark bar at the bottom, like a funky near clip or something? It slowly disappears of the bottom of the screen by about 1000m alt, and also I don't see any effects on the menu screen (from orbit? Is it the same? EVE effects were visible on menu so if I can't see them is it not working or should i get in flight for reals?)

 

I really don't know anything here, if its possible for me to tweak any of these settings? If maybe, would someone please suggest some things to try? Otherwise it's fine - still awesome :) and will be keeping!

Link to comment
Share on other sites

2 minutes ago, Rocket Surgeon said:

Hello!

IT'S SO BEAUTIFUL.

Thank-you! The only problem I seem to have is that dark bar at the bottom, like a funky near clip or something? It slowly disappears of the bottom of the screen by about 1000m alt, and also I don't see any effects on the menu screen (from orbit? Is it the same? EVE effects were visible on menu so if I can't see them is it not working or should i get in flight for reals?)

I really don't know anything here, if its possible for me to tweak any of these settings? If maybe, would someone please suggest some things to try? Otherwise it's fine - still awesome :) and will be keeping!

I knew about the dark bar for a while but it didn't bother me much, I will fix it soon. Effects aren't supported to work in main menu so ignore it and get in flight.

Link to comment
Share on other sites

As requested, Ubuntu 16.04 report here.

Tested on GTX 770 with proprietary 367.35 driver, results are not good so far.

The main issue is performance, it is clearly not enough. It was stable 120fps for 1.0.5 and 1.1.3 and it is 120fps for 1.2.1532 without mods, but its less than 30fps with scatterer even with everything switched off.

As for quality of frame, it seems much better than before, but with some glitches:

Everything but godrays is on:

qdaEbVS.png

sfM4A0J.png

ssEST2t.png

 

No lens:

0vMSPAQ.png

zmVv54n.png

 

No lens, no water and no shadowing:

REM5nTy.png

m8vGgtQ.png

 

This is now game looks without the mod:

VS8A0DK.png

 

Conclusion: FPS is not enough, nasty white dots is nasty.

Image quality is good.

Link to comment
Share on other sites

6 hours ago, Goury said:

As requested, Ubuntu 16.04 report here.

Tested on GTX 770 with proprietary 367.35 driver, results are not good so far.

The main issue is performance, it is clearly not enough. It was stable 120fps for 1.0.5 and 1.1.3 and it is 120fps for 1.2.1532 without mods, but its less than 30fps with scatterer even with everything switched off.

As for quality of frame, it seems much better than before, but with some glitches:

Everything but godrays is on:

No lens:

No lens, no water and no shadowing:

This is now game looks without the mod:

Conclusion: FPS is not enough, nasty white dots is nasty.

Image quality is good.

If you're getting 30 fps there is probably an issue with a shader not loading ot some other null reference. Please look at the logs.

Edited by blackrack
Link to comment
Share on other sites

4 hours ago, blackrack said:

Please look at the logs

Awww... My log for reason unbeknown to me is almost 700MB.

I am a little scared to look at it so Ill just post it here: https://mega.nz/#!0xIwVAJS

 

It was actually 120fps when I started a new science sandbox but after I visited VAB it was 4-12 fps again.

Also there was some problems with shadws (very noticeable at the top left building of the science complex):

ybBMAFe.png

bQPDaeq.png

KYNDPgL.png

8h40Jfo.png

 

Link to comment
Share on other sites

36 minutes ago, Goury said:

Awww... My log for reason unbeknown to me is almost 700MB.

I am a little scared to look at it so Ill just post it here: https://mega.nz/#!0xIwVAJS

 

It was actually 120fps when I started a new science sandbox but after I visited VAB it was 4-12 fps again.

Also there was some problems with shadws (very noticeable at the top left building of the science complex):

Your log should not be 700 mb at all. Try reinstalling KSP completely.  Then try installing scatterer again. Make sure scatterer is the only mod you have installed when you test.  I won't even look at that log if it's that big and I'm sure blackrack doesn't have the time for that either. If you are not willing to even look at it,  why would you ask someone else to comb through something that big?  Try my troubleshooting steps and see if the problem persists. If the problem is still there then go ahead and post your player.log.  It should not be 700mb. That's almost the size of the entire game. 

Edited by Galileo
Link to comment
Share on other sites

26 minutes ago, Galileo said:

log should not be

Yet it is.

26 minutes ago, Galileo said:

reinstalling KSP completely

This is not your шindoшs, there is nothing to reinstall. The log is fresh, the only mods I have is Scatterer and KER, 700MB was logged just in few minutes.

Especially for you, here is log of just few minutes of fresh KSP with just Scatterer and Sqad in GameData: https://mega.nz/#!d55nmC7R

KSP with just Sqad produces about 100kb of log per day.

 

I am not too good with C# so I can't just go and debug it, sorry.

Edited by Goury
Link to comment
Share on other sites

9 minutes ago, Goury said:

Yet it is.

This is not your шindoшs, there is nothing to reinstall. The log is fresh, the only mods I have is Scatterer and KER, 700MB was logged just in few minutes.

Especially for you, here is log of just few minutes of fresh KSP with just Scatterer and Sqad in GameData: https://mega.nz/#!d55nmC7R

KSP with just Sqad produces about 100kb of log per day.

 

I am not too good with C# so I can't just go and debug it, sorry.

Ok,  another thing,  your file is encrypted. So nobody can look at it anyway. And the log DEFINITELY  shouldn't be 700mb after only a few minutes. 

 

Edited by Galileo
Link to comment
Share on other sites

Just quick look reveals megabytes of this:

IsolatedStorageException: Could not find a part of the path "/home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/Sun/sunSpikes.png".
    System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options)
    System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share)
    System.IO.File.OpenRead (System.String path)
    System.IO.File.ReadAllBytes (System.String path)
    scatterer.SunFlare.start ()
    scatterer.Core.Update ()

and this:

NullReferenceException: Object reference not set to an instance of an object
	scatterer.SunFlare.OnPreRender ()

 

So I wonder:

  • How and why ITH it looks in /home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/Sun/sunSpikes.png while game is in /home/goury/proprietary/ksp-1.2-pre and path is set exacly there for execution?
  • Why does this thing tries to load this sunSpikes so many times? It's failed for many times, shouldn't there be retry timeout and limit?

 

Yet sunflare is not the only thing that is not working. There is clearly no water and it may be that there is no nothing at all and the reason for not having glitches like with older versions is actually their non-existence.

T_T

Link to comment
Share on other sites

30 minutes ago, Galileo said:

file is encrypted

Damn those meganz, told em not to encrypt my files but they still do

Those should work:

700MB log: https://mega.nz/#!0xIwVAJS!bgYth1KcbnV_BBKpPHzwq06-NyaAX950zgEzuyQOMkI

200MB log: https://mega.nz/#!d55nmC7R!WgnA-2_a-XrjN4a-JMsC9KNjRimL8rlBGWNaCFXRpoU

 

30 minutes ago, Galileo said:

shouldn't be 700mb after only a few minutes


Thanks, I know how logs should be. Yet blackrack made Scatterer this way.

Edited by Goury
Link to comment
Share on other sites

5 hours ago, Goury said:

Awww... My log for reason unbeknown to me is almost 700MB.

I am a little scared to look at it so Ill just post it here: https://mega.nz/#!0xIwVAJS

It was actually 120fps when I started a new science sandbox but after I visited VAB it was 4-12 fps again.

Also there was some problems with shadws (very noticeable at the top left building of the science complex):

There is no problem with the shadows, they are supposed to look that way, it's a trade-off to make them cover 50+ kms instead of 500 meters.

4 hours ago, Goury said:

Just quick look reveals megabytes of this:

and this:

So I wonder:

  • How and why ITH it looks in /home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/home/goury/proprietary/ksp-1.2-pre/GameData/scatterer/sunflare/Sun/sunSpikes.png while game is in /home/goury/proprietary/ksp-1.2-pre and path is set exacly there for execution?
  • Why does this thing tries to load this sunSpikes so many times? It's failed for many times, shouldn't there be retry timeout and limit?

Yet sunflare is not the only thing that is not working. There is clearly no water and it may be that there is no nothing at all and the reason for not having glitches like with older versions is actually their non-existence.

T_T

So there is a problem with the path on mac, I'll investigate.

There are no timeouts or limit because I don't have time to implement fluff like this. In the screens where you have the flare disabled you clearly have water, so maybe disable the flare and play this way for now.

Edited by blackrack
Link to comment
Share on other sites

5 minutes ago, blackrack said:

on mac

I know nothing about mac nor about chese. I am on Ubuntu 16.04 with Unity 7.4 as DE and Compiz 0.9.12 as compositor.

8 minutes ago, blackrack said:

play this way for now

Anything less than 60fps is not playable for me.

Link to comment
Share on other sites

5 minutes ago, blackrack said:

Then don't play, clearly this mod doesn't deserve to run on your amazing rig.

I can just wait for the fix, I am not in a hurry for playing.

Sadly for the deserve, this mod is GNU GPL v3 (thanks to you, sincerely) so I can run it wherever and whenever I want.

Edited by Goury
Link to comment
Share on other sites

On 25/09/2016 at 11:08 PM, blackrack said:

I would think they aren't because usually shaders with lots of variants and multi-compile directives take a while to compile but I noticed building the asset bundles is really fast and the filesize is always low even if I don't use the compress option.

EVE has even more shader combinations so usually EVE shaders take a while to compile and are heavy in filesize. How long do EVE asset bundles take to build for you?

In any case what's the assetbundle XML and why do we need to generate it?

Unity caches compiled shaders (in Library, iirc), so they take a while if you try to build the asset bundles fresh. The XML is used by KSP to know the contents of the asset bundle. You need it if you're using KSP's asset bundle loader. It's a bit broken, so I only use half of it.

Link to comment
Share on other sites

Ok so this should fix the issue with the paths. @cy4n please test if this also fixes your issue.

@Goury It's easy to fix issues like this and make things better for everyone, but your attitude doesn't help anyone. Take it easy, no one is trying to prove anything.

Without further ado, the fix: https://mega.nz/#!3MYHQQ4a!dtJk49MUyCWwT3CI06VNy7TOQnNNW04MBSNWkvdpAsA

1 hour ago, Waz said:

Unity caches compiled shaders (in Library, iirc), so they take a while if you try to build the asset bundles fresh. The XML is used by KSP to know the contents of the asset bundle. You need it if you're using KSP's asset bundle loader. It's a bit broken, so I only use half of it.

Alright, for now I just avoided KSP's asset bundle loader. I don't suppose there is much point in using it.

Link to comment
Share on other sites

Why this mod have so obnoxius performance even on rig having i7 6700k and gtx 1070 and 32gb ram?Or did ocean thing broke performance? Some features are not optimized yet?? if yes would someone kindly say wich ones??

Edited by Syczek
Link to comment
Share on other sites

3 hours ago, Syczek said:

Why this mod have so obnoxius performance even on rig having i7 6700k and gtx 1070 and 32gb ram?Or did ocean thing broke performance? Some features are not optimized yet?? if yes would someone kindly say wich ones??

Check the debug log for error messages.

Link to comment
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.

×
×
  • Create New...