Jump to content

Disabling the sun flare/texture


KerikBalm

Recommended Posts

The sun appears way too big, and even if you scale it proportionately (so Kerbin:Kerbol size/distance ratio is about equal to that ratio for Earth:Sun) because of some gigantic flare texture that I'd like to get rid of.

Examples:

SOWJfDH.png

Here the middle of the sun is just out of the field of view... but as soon as it comes into the field of view:

Ae5fIxC.png

Same here from Mun:

HygRtcJ.png

taXhFRY.png

How can I get rid of this?

 

Link to comment
Share on other sites

On ‎7‎/‎21‎/‎2017 at 7:48 AM, KerikBalm said:

How can I get rid of this?

If you are not using scatterer...

You can install the mod Kopernicus and then write a .cfg file to modify the sun's "brightnessCurve".  The .cfg should look something like this (where the values shown below are the stock values):

@Kopernicus:NEEDS[Kopernicus]
{
	@Body[Sun]
	{
		ScaledVersion
		{
			Light
			{
				sunAU = 13599840256
				brightnessCurve
				{
					key = -0.01573471 0.217353 1.706627 1.706627
					key = 5.084181 3.997075 -0.001802375 -0.001802375
					key = 38.56295 1.82142 0.0001713 0.0001713
				}
			}
		}
	}
}

The brightnessCurve determines the size of the sunflare, i.e. the bright disk of light you see emanating from the sun (the part that disappears during an eclipse).  In each key, the first number is the distance, the second is the size of the sunflare, and the last two are the in/out slopes for that point.  The distance is kind of weird, it is actually the reciprocal of the distance measured in AU, were 1 AU is defined by the parameter sunAU.  So for example, for the second key the distance is 1 / 5.084181 = 0.1966885129 AU, or 0.1966885129 * 13599840256 = 2,674,932,355 meters.  At that distance from the sun, the sunflare has a diameter of 3.997075.  I have no idea what those units are, but it's all relative.  If you want the sun to have 1/2 the current size, then divide the number in half.  A modified brightnessCurve that would make the sunflare appear exactly half its current size would look like this:

				brightnessCurve
				{
					key = -0.01573471 0.1086765 0.8533135 0.8533135
					key = 5.084181 1.9985375 -0.0009011875 -0.0009011875
					key = 38.56295 0.91071 0.00008565 0.00008565
				}

Note that the slopes have also been reduced by 1/2.  You can play with the numbers until you get something that suits your taste.

You can also change the apparent size of the sunflare in the game by adjusting the value of sunAU.  For example, if you set sunAU = 7000000000, then the game is going to think Kerbin is 2 AU from the sun instead of 1 AU, and the sunflare will consequently look smaller when viewed from Kerbin.  However, I prefer to set sunAU to its actual value (the home world's distance from the sun) and modify brightnessCurve.

If you are using scatterer...

Do what @Galileo says in the next post.

 

Edited by OhioBob
Link to comment
Share on other sites

That a good point by @Galileo.  Everything that I explained was to change the size of the stock sunflare, assuming you are not using scatterer.  If you are using scatterer, then you just want to remove the stock sunflare altogether (scatterer does not remove it).  To do that, do what Galileo said.

@KerikBalm, you weren't specific about whether you were using scatterer or not, though is does look like it in the first and third screenshots (I should have figured it out).  Nonetheless, what I posted is still useful information that somebody might be able to make use of.

 

Edited by OhioBob
Link to comment
Share on other sites

@OhioBob I've been itching for understanding on the brightnessCurve. Now it makes complete sense. :) The first key actually sets the appearance at the greatest distance.....But why is it negative? Is this due to the nature of the curve? (Example, when orbital eccentricity > 1 and KER shows a negative apoapsis.)

I have one small question. Does this affect the scatterer sunflare or is there no tweaking the scale-by-distance for that?

Link to comment
Share on other sites

32 minutes ago, JadeOfMaar said:

@OhioBob I've been itching for understanding on the brightnessCurve. Now it makes complete sense. :) The first key actually sets the appearance at the greatest distance.....But why is it negative? Is this due to the nature of the curve? (Example, when orbital eccentricity > 1 and KER shows a negative apoapsis.)

I have no idea why the stock curve has a negative value, there's really no need for that.  We should be able to give the first key a distance value of zero.  The zero line is an asymptote of the reciprocal of the distance.  That is, the farther and farther away we get from the sun, the reciprocal of the distance gets closer and closer to zero, but it will never equal zero.  The value at zero is the size of the sunflare at infinite distance.  I see no reason for starting out with a negative value, but it doesn't do any harm either.  All that will happen is that any part of the curve that's negative won't ever be used.  (FYI, the brightness curves I wrote for GPP start at zero.)
 

Quote

I have one small question. Does this affect the scatterer sunflare or is there no tweaking the scale-by-distance for that?

I don't know too much about scatterer, but it's my understanding brightnessCurve has no affect whatsoever on the scatterer sunflare.  @Galileo is far more qualified to give an answer on this than I am, but I think I remember him telling me that there is no way to scale the size of the scatterer sunflare with distance.

Link to comment
Share on other sites

@OhioBob Alright. thanks for the update. :D This will come in handy for me soon enough.

5 minutes ago, OhioBob said:

The value at zero is the size of the sunflare at infinite distance.

"Dividing by zero" did come to mind because it's bound to happen. iirc, changing the sunAU can scale the scatterer sunflare but will influence (and upset) functional things too, right? Like solar flux.

Link to comment
Share on other sites

22 minutes ago, JadeOfMaar said:

"Dividing by zero" did come to mind because it's bound to happen. iirc, changing the sunAU can scale the scatterer sunflare but will influence (and upset) functional things too, right? Like solar flux.

There was a time when I thought sunAU was part of the solar flux calculation, but after many experiments I've determined that's not the case.*  So far I've been unable to find any other use for sunAU outside of its role in computing the distance part of brightnessCurve.  If adjusting sunAU allows you to modify the apparent size of the scatterer sunflare, then I know of no other consequences that should prevent you from doing so.

* Solar flux calculations use the distance of the home world from its star as the AU.
 

Edited by OhioBob
Link to comment
Share on other sites

16 minutes ago, AlamoVampire said:

Whats wrong with lens flare? Always thought it neat meself

original post 21:42:30

The OP doesn't like the stock sunflare. By itself it's big and bland. Also scatter is installed so that sunflare should not even be active and overlapping the scatterer sunflare.

Link to comment
Share on other sites

On 7/21/2017 at 11:07 AM, OhioBob said:

You can also change the apparent size of the sunflare in the game by adjusting the value of sunAU.  For example, if you set sunAU = 7000000000, then the game is going to think Kerbin is 2 AU from the sun instead of 1 AU, and the sunflare will consequently look smaller when viewed from Kerbin.  However, I prefer to set sunAU to its actual value (the home world's distance from the sun) and modify brightnessCurve.

Thank you so much for posting this. It probably makes sense to cut/paste that post into the Kopernicus wiki (https://github.com/Kopernicus/Kopernicus/wiki/Syntax-for-stars)

What about for newly added stars? Should sunAU be the average distance between Kerbin and the newly placed star?

Link to comment
Share on other sites

2 hours ago, seanth said:

What about for newly added stars? Should sunAU be the average distance between Kerbin and the newly placed star?

You can really make sunAU anything you want, but you have to make sure it's consistent with brightnessCurve.  I always like to set sunAU equal the the semimajor axis of the home world, and then use that same value for all stars.  Each star's brightnessCurve then has to be written to use that measurement.

Link to comment
Share on other sites

  • 1 year later...
On 7/21/2017 at 12:54 PM, Galileo said:

If you are just trying to get rid of the stock flare when scatterer is installed, use this:

https://www.dropbox.com/s/ua5ty5hnbtpidym/SunFlareFix.cfg?dl=0

this is now an unofficial requirement for scatterer when kopernicus is installed.

note: this removes the stock corona

where is that file now? or how can I remove the stock flare? I also installed sunflares of Maar and it is too big also. Do you know how can I remove the stock flare and also how to get a smaller sunflare of maar.?

Link to comment
Share on other sites

  • 2 years later...
On 7/21/2017 at 6:54 PM, Galileo said:

If you are just trying to get rid of the stock flare when scatterer is installed, use this:

https://www.dropbox.com/s/ua5ty5hnbtpidym/SunFlareFix.cfg?dl=0

this is now an unofficial requirement for scatterer when kopernicus is installed.

note: this removes the stock corona

As the previous person said, I'd also like the file, fsr its deleted

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

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