The exposure, how do?
How to adjust it?
are you talking about your ambient light settings?
if so then click render settings under edit… and just adjust the ambient light .
What you want to do can be accomplished by modifying the intensity of all those lights as they get further from the camera.
I used Flare, this thing seems to be greater and greater, the greater the halo, the more recent example, the smaller the halo.
The lights in the distance, piled up together. Flare also piled up together, it is the exposure. I would like to how to reduce the distance of Flare, and so far marked the elimination of those.
If you reduce the intensity of a light, its flare becomes darker too. To get rid of the buildup of flares you have in the distance, you need to reduce the intensity of lights when they are further from the camera. A script like this:
var fadeDistance : float = 100.0;
function Update() {
//get the distance from the camera
var distance : float = Vector3.Distance(transform.position,
Camera.main.transform.position);
//set light intensity based on distance vs. fadeDistance
light.intensity = Mathf.InverseLerp(fadeDistance,
0.0,
distance));
}
Warning: untested forum code.
I am not familiar with the script, I do not know how to use this script. Depressing.
Can I chime in with a question rather than an answer?
(Sorry if this is annoying…)
Is this artifact similar to how particle systems “grow” as you get farther away? I find that if you make a particle system - like a waterfall or fire/smoke - that the farther way you get the particles become huge in scale and stack up as well. It seems that they actually don’t scale, so as you get farther away, they overlay and addmix until they are a heap of white.
(p.s.: Nice Bridge!)
Actually particle systems in Unity do scale, normally. It is possible (and recommended) to specify a maximum size for particles, though, so you can end up with situations like you describe if your particles are too big or the max size is too small.
–Eric
Har Har! I be piratin’ this 'ere thread!
This may have some relevance to the bridge question posed by Minevr, but in follow up to what Eric was saying, I find that the particle systems I make do not always “scale” and the particle textures addmix on top of each other in a very similar way to the light flares on the bridge.
I find that the particle size itself remains constant, regardless of distance while the placement does scale. This leads to a thin appearance of the particle system up close, and a super dense appearance from a distance.
These are the settings for the particle system:
This scale issue, however, does not seem to be a problem with particles without a texture applied to them. I had a similar particle system attached to my Gem objects, and these do scale with distance properly. So, presumably, this is an issue with the texture applied to the material used in the particle system?
I also discovered that the particles seemed to take a layer priority over the billboard trees. While I was capturing the first set of images, I paid closer attention to the particles in the volcano while playing the environment. At the moment that the trees billboard, the particles move in front of the tree.
Copy it. Make a new script in Unity. Paste contents above into new script. Save script. Drag script on to lights (or add the script to a source prefab if you’re using one). Ensure proper behavior as it’s untested forum code. Report results.
I’d probably build a script that gathers all the lights in its children – dragging the script to each of 200 lights would probably be pretty ugly.
That said, I wouldn’t use lights to produce all those flares. Recipe for horrible performance. I’d use a particle system and take control of the particles OR write a simple sprite implementation (basically a plane facing down its Z-axis with:
// simple sprite script
function Update() {
transform.LookAt(camera.main.transform.position);
}
and simply assign the appropriate material to each plane. The “flares” will scale exactly as you expect with no extra code.
If you have multiple cameras there’s a little bit more work involved.
True enough, hence my comment (and hopes) that a prefab of sorts might be in use. Great comments on non-light based solutions too!
I’d guess it’s because you’re using such large sizes for the particles. 15-20 is awfully big, and your max particle size is .1 (i.e., 10% of the screen size), plus the size grow isn’t helping. I mentioned that you can get the “no scaling” effect this way–the particles are clamped to 10% screen size max, so they won’t get any bigger than that, and therefore they are prevented from being drawn the size they “should” be up close. As they move farther away, they appear not to scale because of being clamped. If you increase the max particle size, then the effect would be reduced, but you probably want to use a more realistic particle size instead. Or both, but having lots of huge particles will burn through fill rate.
–Eric
Eric:
Excellent, thanks.
You helped me crack it with “1 Max Particle Size” = “100% of your screen”. I can try and balance the effect I’d like with that understanding.
From a compositor’s stand point, the add/mix effect of the particles is very similar to that of the flares on Minevr’s bridge. I see how, tho’ artistically similar, these artifacts come from completely different sources.
I’ll open another thread about the particle layer priority and the billboard trees, and get out of Minevr’s topic. (Sorry, Sir Minevr…)
FYI - Max Particle Size is not represented in the doc’s (file:///Applications/Unity/Unity.app/Contents/Documentation/Documentation/Components/class-ParticleRenderer.html), which I had read through - not that I’d’ve picked up on the significance of it if it’d been there. Once you mentioned it, I had to go back and check the docs, and it seems to have been omitted or overlooked.
I get it, use the following code
var fadeDistance : float = 100.0;
function Update() {
//get the distance from the camera
var distance : float = Vector3.Distance(transform.position,
Camera.main.transform.position);
//set light intensity based on distance vs. fadeDistance
GetComponent(LensFlare).brightness = Mathf.InverseLerp(fadeDistance,0.0,distance);
}
wait how do i lift this clamped to 10% of your screen limitation ??? where is this specified ?
(we are game-developers not little children we should be allowed to break our own games if we want to )
As mentioned, change the max particle size.
–Eric