Jump to content

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

Recommended Posts


Scatterer is a graphical mod created primarily to add realistic atmospheric scattering to Kerbal Space Program.

The mod was subsequently extended with other graphical effects that add to the game's atmosphere and now covers the following:

  • Atmospheric scattering
  • Ocean shaders (with transparency, sky reflections, foam, refractions and underwater effects)
  • Better sunflare rendering
  • Godrays and terrain shadows
  • Visible eclipse shadows
  • Integration with EVE (clouds mod) to display effects and color changes on clouds





v0.052: Anti-aliasing, sunset lighting, ocean shadows and fixed tsunami bug



           In the screenshots, you have stock EVE, latest scatterer, and for the part shaders Textures Unlimited with some moduleManager patches for stock parts (can't remember where I grabbed it but probably this https://spacedock.info/mod/1841/Textures Unlimited Default Stock Config - Unofficial)


Full album https://imgur.com/a/gLhsAT1


v0.0320-320b: water refraction



Full album http://imgur.com/a/xahKF


Older albums:

v0.0300: EVE cloud integration



Full album http://imgur.com/a/dhhFK


Godrays and terrain shadows album: https://imgur.com/a/4LhYC

Older ocean album: http://imgur.com/a/JJDaU

Older album: http://imgur.com/a/hPiEu#0

Old album by BrutalRIP: http://imgur.com/a/gMX93



The videos in this section are a bit old and a few versions behind, anyone feel like making a fresh video? :)





UI can be toggled with Alt-F11 or Alt-F10

If that doesn't work try shift-alt-F10 or shift-alt-F11 

RSS compatibility (outdated configs)


I don't provide configs for RSS, I believe pingopete is working on providing these (RVE mod) if you wish to play with RSS and reuse the configurations I have created for stock, at least for Earth and Mars put the following in the "config/planetsList.cfg" file:


        celestialBodyName = Earth
        transformName = Earth
        loadDistance =50000000
        unloadDistance = 100000000
        hasOcean = true
            Item = Moon
        celestialBodyName = Mars
        transformName = Mars
        loadDistance = 50000000
        unloadDistance = 100000000
        hasOcean = false
            Item = Phobos
            Item = Deimos

You also need to rename the "Duna" folder to "Mars" and "Kerbin" to "Earth".

It used to be that RSS only changes the name of the CelestialBody to Earth and leaves the scaledversion transform/gameobject named Kerbin. However with the most up to date version of RSS both celestialBodyName and transformName for the Earth are the same. When running older versions you'd need:

        celestialBodyName = Earth
        transformName = Kerbin

If you get issues with null references or the sunflare not working, try the one above.

The sun flare is tailored for the stock system but resizing it for RSS is easy, Just replace these lines flaresSettings andspikesSettings in the sunflare.cfg file with this

flareSettings = 0.45,1,0.085

spikesSettings = 0.6,1,0.1

Config points:


Config points are a system that allow you to define different value for settings at different altitudes, at each altitude a "point" is defined. This allows to tweak the settings to improve the look or work around artifacts at any altitude.

Each point is a combination of an altitude value and scatterer settings.

All config points are, and have to be sorted by increasing altitude, otherwise bad things happen.

When below the altitude of the first point (number 0), the settings values of that point will be used as they are.

When between the altitudes of two points (example point 0 and point 1) a mix of their two settings will be used based on the current altitude. Example, if point 0 is set at 1000m and point 1 is set at 5000m, the values used by scatterer at a 2000m altitude will be 75% of point 0 + 25 % of point 1. Hope this makes sense.

When passed the altitude of the highest point, the values of that point are used as they are. These are also

You can browse between the config points, delete and add new ones in the UI. Always make sure to have them properly ordered by altitude.

You can press the "show interpolated values" button to view the current values and how they are computed.


Planned features:


-Planetary eclipses with atmosphere and terrain shadowing (in progress)

-Support for planetshine from nearby planets in the atmosphere lighting and scattering, terrain lighting and ocean reflections. (in progress)

-Godrays/scattering occlusion (in progress, removed from latest versions to fix other issues)

-Ambient occlusion and depth of field

-HDR rendering

-Screen-space reflections for the ocean.

-Refractions (done) and underwater caustics

-New terrain system

-Global illumination


Current major issues:


-Terrain shadows might cause weird, moving patterns to appear across the landscape, adjust shadow bias and shadow normal bias to fix this (for more info on what these do, go here http://docs.unity3d.com/Manual/ShadowOverview.html and scroll down to "Shadow Mapping and the Bias Property"). You can also try to turn up the rendering quality in KSP, mess with anisotropic filtering settings in the driver or force directx11. Note that why this is fixable for some people, for others nothing helps, if it doesn't work for you please don't complain.

-Sometimes the game starts stuck in the KSC view zoomed on the SPH, whenever that happens press alt+f12, show input stack and press clear input lock and it fixes it, this is actually not a scatterer issue but gets reported here a lot.

-Clip plane issue with rescaled mods (with 2 solutions linked): https://github.com/LGhassen/Scatterer/issues/66

-RSS/rescale mods might not actually work and may have several issues.


How to report Issues (important, please read if you want your issue taken into consideration):


For correctly reporting issues read this and follow the instructions, if you don't follow the instructions, your report will be ignored

Follow the template, if you're too lazy here's the copy-pasted, adapted example:

KSP: 1.3.1 Windows 64bit

Problem: Flickering ocean

Mods installed:

Scatterer 0.0324

EnvironmentalVisualEnhancements 1.2.2-1

Reproduction steps:

With ocean shaders enabled, default scatterer settings: Launch a ship from KSP, look at ocean, ocean flickers (appears and disappears) very quickly.


<link>Output_log.txt (preferably dropbox or pastebin link)

Copy this, fill it in, add your log file and submit it. You can find your log file here: Local Disk\Users\<username>\AppData\LocalLow\Squad\Kerbal Space Program

Preferably submit your issue on github https://github.com/LGhassen/Scatterer/issues it will ease your life and mine.

(Sorry for the big red text and being a bit pushy, but a lot of people don't follow these instructions and I get overwhelmed :))

Config tool


config tool is DX11 ONLY!

This config tool will allow you to generate new precomputed tables for the atmosphere, basically this is the only way to tweak atmosphere colors.

I haven't updated this in a while but you can ignore the planet name field.

Rg is the planet radius (it says diameter in the tool but it's wrong) Rt is the height of the atmosphere. RL is the limit of the atmosphere but it works weird.

(Keep in mind it is not important what the actual value of Rg, Rt or RL is, what matters are the ratios Rt/Rg and Rl/Rg, Rg is automatically scaled to your chosen planet's radius, Rt and RL are scaled by factors of ChosenPlanetRadius/Rg)

Also, you don't need to change Rg from the original value, just copy everything into KSP and it'll rescale automatically.

Half heights are the height in km that half the particles are found below. If you modify Rt and Rl you have to modify these or you get artifacts.

To use this, just enter your settings and press generate, if you're satisfied with the result, copy the .raw files (ScattererTool_Data\Proland\Textures\Atmo) and  manually open the .xml file (\ScattererTool_Data) from the tool folder and copy the settings into your planet of choice's settings.cfg file in the scatterer folder and replace the files in the scatterer mod folder with them. As of scattererv0.024 (1.1 compatibility update), scatterer now uses .half files, any .raw files will be converted to .half IF NO .half FILE EXISTS. Therefore copy the .raw files like usual and delete any existing .half files, the new .raw files will be converted automatically to .half, you only need to distribute the latter.

Sorry this is a bit messy, I'll try to update this tool soon.

Here's an example of what you can do with the config tool: GGCwDqj.jpg

And the result in KSP:



Some more ingame examples:




-Fix occasional black screen when reverting to KSC
-Compatibility with EVE-Redux's volumetric particle fading near camera
-Caustics don't appear on shadows
-Small performance improvement when using ocean shader (CPU usage reduction)
-Ocean builds/loads faster if compute shader support is available, m_variance variable is hidden from user
-Added option to disable dithering from sky and scattering effects

-Support for performance-enhanced EVE version: https://forum.kerbalspaceprogram.com/index.php?/topic/196411-110x-eve-redux-performance-enhanced-eve-build/
-Fix wrong overriding of EVE renderqueues

-Update for 1.10
-Fix stock sky and scatterer sky drawing on each other in 1.10
-Fix z-fighting and scattering rendering twice on stock ocean

-Fix issue with VesselView mod resulting in black ship view screens
-Display effects in main menu for modded planets other than Kerbin

-Fix for 1.9.x (Maintain compatibility with 1.8.x)
-Fix for flickering shadows in Dx11 (stock game bug) (with option to disable it just in case)
-Temporary fix for EVE clouds sinking into planet in 1.9
-Temporary fix for EVE clouds being visible in plumes (thanks @R-T-B)
-Handle long-distance shadows on 1.9 Dx11 with a custom method
-Separate shadow settings for new unified camera mode (1.9 Dx11) and other modes using dual cameras
-Added options to override shadowMap resolution with long-distance shadows (defaults to 8K in unified camera mode, can be lowered along with shadows distance for saving performance)
-Added options to override shadowCascadeSplits with long-distance shadows
-Fix compatibility with stock reflection probes
-Fix planets and scaledSpace scenery being visible through other planetSurfaces in stock reflection probes (stock game bug)
-Fix ocean shadow artifacts
-Fade out ocean shadows correctly
-Fix foam/whitecaps becoming invisible in some situations
-Fix shores having weird scattering (mostly RSS/rescale bug)
-Fix Kopernicus ring shadows broken since Kopernicus refactor (only linear rings supported, tiled rings will not cast shadows)
-Fix issue with some cargo bays (stock drag cubes) causing low framerates and errors
-Added new setting to partially flatten scaledSpace mesh geometry, to be used when "naked" scaledSpace geometry is visible behind localSpace scattering and terrain (Kerbin needs this in 1.9)
-New, more readable options menu layout
-Better logging when initializing Scatterer celestial bodies

-Added water caustics, configurable
-Add possiblity to change sun color for atmospheres (possibility for colored suns, coloring atmospheres differently)
-Fix issue with symlinks in paths
-Fixed issue with oceanRefractions setting not getting saved
-Fixed crash due to atmosphereProjector destructor
-Fixed some issues when starting unity in debug mode

-Update for 1.8
-Disable dithering on sunflares because of pronounced artifacts

-Fix refraction/transparency artifacts in the ocean at altitude (swirly appearance)
-Fix unnaturally bright scattering on the ocean and a small pop while transitioning to orbit
-Fix white sky bug in some situations
-Add trailing zero in version number for CKAN

-Fix z-fighting (flickering black squares on terrain when high in atmosphere)
-Fix overlay/atmosphere visible on ships in orbit

For end users:
-Anti-aliasing on atmosphere effects (fix black edges on horizon, sea and terrain)
-All effects compatible with camera mods (rasterprop etc...)
-Removed godrays to add the previous two points
-Sunlight color is tinted by extinction (objects receive red light at sunset instead of white)
-Fix tsunami/flood bug in KSC scene, and with Kerbal Konstructs
-Fix line break in scattering effect
-Automated and improved transition to orbit with less pops/discontinuities
-Ocean ambient light (ocean visible at night)
-Shadows visible on the ocean (may be buggy in dx11)
-Sunflare visible in supersampled screenshots
-Display scatterer button in KSC menu only
-Improved shadow precision
-Sunflare scales with FOV
-Fix performance high performance hit of dithering in OpenGL on certain machines (thanks @soulsource)
-Don't break stock underwater effect with stock ocean
-Fix buggy ocean surface when lowering ocean resolution
-Fix ocean pixel lights
-Fix various artifacts
-Moved settings that change every time to pluginData

For modders:
-Merged local and scaled settings (scattering+extinction), to reduce clutter
-Removed mapSkyExtinctionRimFade, mapGroundExtinctionFade and _mapExtinctionScatterIntensity 
-Added a new setting extinctionThickness, setting it works on localPostProcessing, scaledSpace and clouds. . It works as (1-extinctionGroundFade),
-Removed other redundant/unused settings
-Fixed extinction tint not doing anything
-Mapnode removed, map mode just uses the highest config node
-Created a repo for stock scatterer config, to track config and syntax changes, you can sue it like this
-Fix not being able to add sky effect to atmosphere-less bodies
-Update to 1.5.1
-Fix stock sunflare appearing on top of custom sunflare
-Fix effects flipped when AA is disabled
-Add mod button to toolbar and remove intrusive mod menu from main menu (new icon by cratercracker)
-Display effects in main menu

-Update EVE shaders (fading rim)

-Fix issues with B9PartSwitch resulting in invisible water and weird sky shading
-Fix some issues with banding in the sky and underwater

-Fix issue where space is black and planets are invisible
-Fix flipped post-processing without AA on direct3D
-Fix gas giants visible through other planets
-Fix refraction and post-processing effects not applying to new mk1-3 pod 

-1.4 Compatibility
-Fix postProcessing effects not applying to trees (atmospheric scattering) or fairings (underwater)
-Fix/Minimize white aliasing around objects when in front of the ocean

-Fix nullref spam with refractions on
-Fix ocean "stuck" in the screen and visible on the moon and other bodies
-Fix black sky in KSC view when reverting mission
-Fix halo issue and remove alternateSQRT option
-Fix atmospheres visible through other planets
-Fix nullref issue on planets without PQS
-Recompiled for 1.3.1

-1.3 compatibility: fixed flying tiles issue

-New water effects: Water refraction, depth-based transparency, contact foam and underwater surface and underwater "fog"
-Fixed "break" in the postprocessing effect very close to the camera
-NearClipPlane parameter is back in the config file per popular request, not recommended to mess with it unless you know what you're doing
-Fix some issues with disappearing layer2d (used for spectra glow effects)
-Changed config file structure to improve ModuleManager compatibility
-Added option to disable planet config auto-saving on scene change
-Per-planet EVE integration
-EVE integration: option to preserve cloud colors, prevents "bleached" clouds when using EVE integration
-Fixed a few EVE integration issues causing clouds to appear black on some configs

-EVE cloud integration, scattering is now applied to clouds and they change colors at sunset (old shading still an option from main menu, useful for EVE 7-4 and visual packs that aren't reconfigured for the new system.
-Added kopernicus ring shadows, rings can now cast shadows on planets (if using the new EVE integration, the shading may not look right, it's better not to have clouds on a planet that has rings ATM, old cloud shading works fine).
-Sunflare changes intensity and color when seen through Kopernicus rings.
-Added sun flare ghost fade-out after a configurable distance.
-Effects now work in tracking station.
-Fixed atmospheres wobbling when observing far away planets in map view, ie planets that the active vessel is not orbiting.
-Fixed ocean reflections and foam being very faint.
-Fixed "experimental viewdir offset" flipping directions sometimes, this should fix the band over the horizon.
-Fixed re-entry effects rendering behind ship.
-Removed nearClip Parameter and fixed "slicing" on objects close to camera.
-Fixed ocean and postprocessing shaders causing artifacts on Texture Replacer's reflections.
-Fixed high ambient light issue on ship when disabling ambient light in scaledSpace.
-Fixed whole screen being tinted with color of sunflare when being very far from sunflare source
-Fixed rectangular artifacts on sunflare ghosts
-Sunflare now shows correct extinction from all distances, previously all extinction effects disappeared when the PQS is disabled.
-Planets now have an individual "mainSunCelestialBody" setting. Useful for multi-star system mods.
-Fixed OpenGL on windows

-Recompiled for 1.2, fixes map errors spam
-Added potential fix for atmosphere halo (if it doesn't work, try switching it off)
-Switched sky shaders to soft blending, objects seen through atmo and planets from orbit might look a little different, let me now if old one is better

***********v0.0255*********** Released for 1.2 and 1.1.3
-ModuleManager compatibility
-Fixed several issues with EVE cloud shadow issues for 1.2
-Fixed overbright atmosphere edge in map/orbit view in 1.2

-Compatibility fixes for linux and mac
-Possibility to set name the main celestial body considered as the sun (useful for kopernicus)

-1.2 Compatibility
-Fixed ocean spazzing out when zooming out or rotating camera
-Multiple lens flares support

-Fixed lens flare compatbility with 1.1.3
-Godrays no longer cause black trails behind ships/buildings
-Fixed weird halos around planet

-Fixed terrain shadow artifacts (adjust shadow bias and shadow normal bias if you still get issues)
-Fixed 3rd sun flare ghost displaying image of 2nd ghost

-Fixed ocean FOV and IVA-related issues
-Fixed compatibility with Directx11
-Fixed lens flare in OpenGL
-Fixed weird looking eclipses on Jool
-Doubled number of sun flare ghost instance slots and added a ghost texture slot
-Sun flare now fades out when zooming in on the sun so the sun surface is visible

-Added accurate sky reflections on the ocean
-Added option to enable light sources to work with the ocean (big performance hit at the moment)
-Mostly fixed horizon line artifacts
-Ocean now appears in supersampled screenshots
-Issue where ocean flickers and bobs around with camera movements appears to be fixed
-Moved fourierGridSize option to the main menu (option with the biggest effect on ocean performance)

-Added a way to override rendertype tags (fixes rectangles in the sky when using EVE clouds or from rocket exhausts)
-Updated the "render on top of eve clouds" option to match EVE's new renderqueue (gets rid of weird terminators with EVE)
-Tweaked and recompiled shaders for unity 5 (should get rid of some rendering issues new to unity 5)
-Terrain shadows are now disabled by default to avoid heavy artifacting in dx9

-Fixed weird and greenish coloration in postProcessing shader and sky shader especially visible near the horizon, both effects are back to being realistically blue.
-Fixed eclipses nor working correctly in map view when viewing planets other than the active one.

-1.1 Compatibility
-Much faster, nearly instantaneous loading, reverting a flight you no longer have to wait 10 seconds, effects enabled in map view for planets other than the active one and will load on demand.
-.raw format replaced by .half format, which enable faster laoding and smaller filesize, if you created your own .raw files using the config tool, delete the .half files and any .raw files will be converted automatically to .half the first time the planet is loaded. YOU ONLY NEED TO DISTRIBUTE THE .half FILE.
-Option to disable scaledSpace ambient light (celestial bodies appear realistically lit and will display as crescents in the sky)
-Restored the sun corona.
-Option to ignore renderType tags, keep this on for the time being as rendertype tags seem to be gone in 1.1 and the postprocessing shader won't work without them.
-No longer need to reload the tables when switching fullscreen/windowed, only ocean needs to be reloaded.
-Added an ocean offset reset when it gets bigger than 20000, avoids floating point precision issues resulting in artifacts or a blocky-looking ocean when traveling a large distance over the ocean such as doing a sub-orbital hop or doing a fast re-entry.
-Window positions are persistent.
-Gui keys are rebindable through the config file.

-Quick fix to effects disappearing in scaledSpace for RSS
-Ocean fourierGridSize restored to 128 as default for Kerbin

-Fixed compatibility with planetary rings
-Fixed lens flare not occluding correctly on bodies without atmosphere
-New option to draw the atmosphere over EVE clouds: Fixes strange-looking terminators when using both EVE and scatterer and looks smoother in general, however it makes the transition from PQS to scaledSpace more problematic and introduces some new issues. Can be toggled of from the main menu or for individual planets throught the planetsList.cfg file.
-Fixed draw order issue where clouds on Jool render over Laythe's sky.
-Partially fixed compatibility with telescope mods: Will work correctly in high orbits (>160 km) with the planet rendering correctly and no overlaying layers, however will get some interference from the postprocessing shader when PQS is active (below 160km for Kerbin).
-Visor reflections (TextureReplacer's reflection plugin) should also be fixed, with the same limitations as the telescope mods.

-Huge memory usage improvements (100-400 mb savings)

-Fixed lens flare shader not working on linux/OpenGL
-Fixed pink square that appears near the player's craft
-Fixed extinction tint not working in sky shader and postprocessing shader in OpenGL

-Fixed completely blue screen issue when loading a craft in high orbit
-Fixed blue screen and tilted camera issue when entering KSC

-Ocean no longer disappears when you rotate the camera, do flips in IVA or get to orbit.
-FakeOcean removed, regular ocean stays all the way to high orbit.
-Added ocean alpha setting to configPoints to fade out the ocean nearing orbit.
-Better way to disable the stock oceans (thx to rbray89), gives a small performance bump.
-Added godrays: Early WIP, disabled by default, these work best with good terrain so turn up your terrain quality. Looks best with terrain shadows.
-Added terrain shadows: These depend on the unity shadows, if you see shimmering or artifacts turn up your shadow quality through the "render quality level" slider in KSP. The default shadow Cascades setting of 4 seems to work quite well. Shadows distance has also been changed from 5 000 to 100 000, this is adjustable in the scatterer config file.
-Added custom sunflare shader: WIP, configurable through custom textures and config file.
-Added eclipses: WIP, appear only on sky and orbit only for now, no terrain shadows. You can set eclipse casters through the planetsList file.
-Tweaked configs for a bunch of planet, ground to orbit transition is much better on Kerbin especially. Didn't have time to redo Duna so it probably loooks really bad.
-Fixed custom depth buffer artifacts (threshold of 10 is enough for all altitudes now).
-Moved all render modes to the custom depth buffer.
-MapViewScale setting no longer required.
-PostProcessing now has extinction like the sky shader.
-PostProcessing blending mode changed from alpha blending to soft additive, basically it blends better and feelsless foggy during the day and more foggy at sunsets/sunrises.
-Sky extinction is now handled via analytic formula, this fixes the bug where sometimes extinction doesn't work with custom configs, beware that objects in the sky are still handled via the old method so this may not fix it. It also looks a bit different so you might have to redo your configs.

-Fixed black ocean bug
-Fixed issue with gas giants giving abysmal fps
-Fixed rim exposure settings resulting in pixelated planet edges
-Fixed atmosphere drawing over planets in map view
-Fixed sunsets/sunrises looking like eclipses
-Sunglare hiding during eclipses
-Cleaner depth buffer and postprocessing in dx11 and opengl (edgeThreshold now obsolete)
-Main menu window for enabling and disabling features

-Minimized z-fighting on the fake ocean
-In addition to their alpha and depth settings, the postprocessing and fake ocean both fade out automatically following how much the PQS is faded out.

-Added ocean faking in postprocessing, prevents rendering the expensive ocean when far away and used in orbital view instead of showing the ocean floor.
-Added variables to fade out the foam and the ocean alpha with distance (seafloor no longer visible in the horizon, "foam wall" removed)
-Added variables to control the exposure and extinction for the edges of the atmosphere separately (also fixes the atmosphere "barrier" effect)
-Fixed sunglare visible through planet and in space

-Fixed the "halo around planets" bug in dx9
-Fixed engine effects displaying on top of ocean when they are behind it

-Fixed issue were reverting flight causes effects to disappear
-Added control/scaling of atmosphere height directly ingame
-Tweaked config for Kerbin: 2x higher atmo, blue sky is visible higher
-1.7x atmosphere height on Laythe
-2.5x atmosphere height on Eve

-Ocean shaders, first public release

-Fixed RSS compatibility, Any Kopernicus / RSS planetary system configuration should be auto compatible now regardless of celestial body and/or transform names and fixed a bunch of bugs, Shaders, configuration and textures are now located dynamically either by celestialBodyName or transformName defined in PlanetList.cfg (thanks to direwolf/tarsolya)

-Added workarounds for most opengl/dx11 artifacts (24bit depth buffer can be turned on/off in planetslist.cfg, openglThreshold and edgethreshold need to be configured with config points)
-Fixed mie scattering in the post processing shader
-Tweaked configs for Jool (now green), Eve and Laythe
-Added sunglare scaling

***********Changelog for 0.019[/B]:
-Multiplanet support
-Fixed nullrefs at start

***********Changelog for 0.01781[/B]:
-Window starts hidden.

***********Changelog for 0.0178[/B]:
-Added compatibility with RSS, to use with RSS replace config file with the one in "RSS compatibility folder" or go into the config file planetName and change the celestialBody to Earth but keep the other name to Kerbin.
-New orbit shader, tweakable through the parameters sky extinction and sky extinction tint.

***********Changelog for 0.0175[/B]:
OpenGL fixes:
-Lines in the sky bug fixed permanently (without needing forceOff aniso)
-Rainbow coloring/discoloration fixed
-Moire patterns fixed (also fixed in dx11)
A little better OpenGL performance

***********Changelog for 0.0171[/B]:
-Dx11 compatibility fix

***********Changelog for 0.017[/B]:

-Full compatibility with EVE clouds
-New orbital effect/view (EVE clouds recommended)
-Celestial objects now visible in the sky
-Added config points as a way to set different settings for different altitudes and smooth out between them
-New UI for config points
-More discrete default settings, less foggy
-New, smoother depth setting function (scattering effects no longer seem to start at a visible barrier)
-Fixed blending issues (Black bars at the edge of the atmosphere, barrier effect when going up etc...)
-Fixed z-fighting issues and weird stuff at orbits beyond 200km
-Fixed atmosphere displaying over moon and other celestial objects randomly
-Fixed effect in map view
-Map view now has separate settings which only trigger in map view.
-Fixed ForceOFF aniso setting not persisting/loading right

***********Changelog for 0.0151[/B]:

Just a quick fix for the pink objects bug

***********Changelog for 0.015[/B]:

-Lowered memory usage (I expect your feedback on this)
-Added persistent settings
Settings can be saved with the save settings button or they get saved automtically when the scene is changed.
-EVE clouds are now visible in the sky (postprocessing still draws over them though)
-Added toggle aniso button for people who are still getting the lines in the sky when using OpenGL (if you don't have the bug don't use this, if this still doesn't fix the bug try disabling aniso if you have it forced from the drivers)
-Terrain should no longer be low-res
-Fixed some minor bugs

***********Changelog for 0.014 Experimental version[/B]:

-Effects no longer lag behind as you move the camera.
-Auto depth adjustment based on height (WIP/experimental).
-Kerbin no longer covered by blue sphere after altitude of 160 Km.
-New view from orbit faded out progressively as you approach scaled space (extremely WIP/experimental, has some artifacts)
-Few adjustments to the base settings, more subtle effect.
-UI now defaults to hidden, can be enabled with Alt-f11 or Alt-f10.
-The mod no longer disables anisotropic filtering and forcing aniso through drivers no longer causes artifacts
-Other minor fixes


I do this for free in my spare time, if you like what I do you can support me here:




ccK3fOi.png  16N9cgB7Ht5LAY9ASv9gcvbLRhnX4T5kzN

Download link(KSP 1.10.*):


Alternate: https://github.com/LGhassen/Scatterer/releases

Config Tool link:






Fanart corner:

fanart by @cratercracker


fanart by @01010101lzy




Edited by blackrack
Link to post
Share on other sites
This is what I missed for a very long time.

Do you also have any plans to support RSS in future?

Yes, this shouldn't be hard to do, I also plan to include a way to configure it for mods that add custom planets.

Link to post
Share on other sites

There are some atmospheric scattering effects in EVE (you can see them in Astronomer's pack), but this one looks promising because EVE will be dead in 1.0 most likely, as RBray is no longer interested in updating it it seems.

Link to post
Share on other sites
There are some atmospheric scattering effects in EVE (you can see them in Astronomer's pack), but this one looks promising because EVE will be dead in 1.0 most likely, as RBray is no longer interested in updating it it seems.

*cough*unless Squad hired Rbray to stockify EVE for 1.0*cough*

Oh my.. sorry. Allergies. Tis the season.

Seriously though this is awesome. I hope the two can one day be combined.

Link to post
Share on other sites

I found a temporary fix for the line artifacts, simply bump the visual settings down to "fast", this doesn't seem to affect KSP's visuals much but it disables shadows.

Seriously though this is awesome. I hope the two can one day be combined.

I don't see a reason why this wouldn't happen, I've already seen someone combining this with clouds.

Edited by blackrack
Link to post
Share on other sites
Which components of the Atmosphere do you want to deactivate exactly? With this little function I threw together, you can deactivate the mesh-renderer for the atmosphere, but that results in a black "atmosphere" in the PQS-view.

public void DeactivateAtmosphere(string name)
Transform t = ScaledSpace.Instance.transform.FindChild(name);
for (int i = 0; i < t.childCount; i++)
if (t.GetChild(i).gameObject.layer == 9)
// Deactivate the Athmosphere-renderer

// Reset the shader parameters
Material sharedMaterial = t.renderer.sharedMaterial;
sharedMaterial.SetTexture(Shader.PropertyToID("_rimColorRamp"), null);
sharedMaterial.SetFloat(Shader.PropertyToID("_rimBlend"), 0);
sharedMaterial.SetFloat(Shader.PropertyToID("_rimPower"), 0);

// Stop our script
i = t.childCount + 10;

If you just want to modify the color of the rim (horizon), you have to manipulate the CelestialBody component. If you have questions, PM me :)

Thanks a lot, I'll try this code and experiment with it later today.

Right now my atmosphere renders as pitch black during the night, I can make it transparent below a certain threshold in order to be able to see the stars and the moon at night but the stock atmosphere effects end up messing with it during sunrise/sunset. I didn't know the stock atmosphere had components but I'll probably disable them all.

Anyway, if you're familiar with meshes, if I use a meshrenderer for my atmosphere I have a huge performance drop, everything starts running at 5 fps. What's the deal with this? I'm currently rendering my atmosphere with graphics.drawmesh to get around this. Also, there are the line artifacts described in the OP which go away when i drop the visual settings of the game to fast.

Link to post
Share on other sites

I had posted about this in the texture replacer mod thread once, but it didn't seem like it would be possible via that mod.

I'm looking for a mod that can make less of the skybox visible while on the surface of a body with atmosphere and you are on the night side. My original idea was to use texture replacer to add a second skybox behind the first. The first one would contain gas clouds, nebulas, galaxies and other phenomenon that are not normally visible from within atmosphere. That layer would have it's alpha level dropped as you plunge into atmosphere, and vice versa. It should never reach 100% either, so that you can always see the same stars behind/through it.

Seems that my idea would require a plugin of it's own, which I have no idea how to write. Perhaps this is a feature you may want to explore.

Link to post
Share on other sites
blackrack, could you please upload your preview version to another hoster? I can't reach MEGA for whatever reason.. :(

Here you go, I trimmed off the fat so this version should have better performance than the first.


I had posted about this in the texture replacer mod thread once, but it didn't seem like it would be possible via that mod.

I'm looking for a mod that can make less of the skybox visible while on the surface of a body with atmosphere and you are on the night side. My original idea was to use texture replacer to add a second skybox behind the first. The first one would contain gas clouds, nebulas, galaxies and other phenomenon that are not normally visible from within atmosphere. That layer would have it's alpha level dropped as you plunge into atmosphere, and vice versa. It should never reach 100% either, so that you can always see the same stars behind/through it.

Seems that my idea would require a plugin of it's own, which I have no idea how to write. Perhaps this is a feature you may want to explore.

I guess this is feasible, though I'm not personally interested in it I guess I could make it an optional feature or a separate mod once I'm done polishing up this one.

Im not really familiar with the meshes, but with the structure of the atmospheric components. :)

For the black pitch during night: Did you replaced the material with a material from scratch? If yes, renderQueue could be the problem. (Sorry, can't look at the source atm)

I just rendered a completely new mesh with it's own shader and material that occldue the old sky but didn't set any alpha transparency. I did this now but sill have to remove/tweak the old atmosphere and my messed up dx9 shader.

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.

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...