Is LightRange and lighting screwed up?
Blitz3D Forums/Blitz3D Programming/Is LightRange and lighting screwed up?
| ||
LightRange should default to 1000; however, I am getting spurious results. I noticed this with point/omni lights. Create a light - preferably change it from default white light. Look at the results if you simply add LightRange, light,1 - just a single unit makes a huge difference. Without setting LightRange, the colours are pretty much gone - just setting a LightRange of 1 brings them back. Anyone else seeing this? Surely this didn't happen previously? |
| ||
I dunno, I've never really noticed any particular changes at all with LightRange. |
| ||
I just think that 1000 is never a good value. I always put 15 or something like that. Well, even if it's "turned off" by default and just by changing the range it will turn on, that's fine by me. As I previously said, I never use that much range. |
| ||
Surely this didn't happen previously? downgrade to another version and check |
| ||
LightRange has never been accurate tbh :S |
| ||
I thought it had a default setting of 1000 when you create a light - that is what the manual suggests; however, it appears it does not apply to point lights. I am sure that sometime in the past it did as I seem to remember having to reduce LightRange. No big deal - I just wondered if it was just a bug that nobody had noticed. |
| ||
I did a little experiment for you and this is what I came up with: A point light was created here, then colored orange, with a LightRange of 15: The light is centered on (well, it looks just a tad off) the fire pit down below. You can clearly see the 15 "unit" radius on the ground as the light is actually placed over the ground, not at the fire location. (It sits 2 blitz units above the ground.) You can also see it lights the castle towers far away from the fire, at least 50 blitz units away. If you look real close, the 15 unit light even slightly lights the hills beyond to the rear of the castle. You know, from this shot it looks like point light range is in a square radius maybe? 15 units each way, not in a true radius? Maybe it's just me, but it looks like a 30x30 box. ![]() Now, I simply commented out the LightRange command and the colored light is much, much, much further, without the need for a LightRange, light, 1. You can clearly see that the orange light has flooded everything. Setting the LightRange to 1 essentially turns it off in this case, as the light radiates from 2 units above the ground, it doesn't even light it. ![]() I deleted the LightColor line of code and got the same result as with the orange light: It goes as far as I can see with this program, with no LightRange line. Edit: I'm using version 1.98. |
| ||
I think the "Box" appearance is because the ground must be low-poly. That way there are fewer vertices and that "triangle smooth gradient" artifact is more visible, because the light concentrates on the vertices:![]() Try to tesselate the ground in your modelling program just to increase the vertex count and test it again. PS: Nice scene you got there! |
| ||
Ah yes, that is the case. Flipping to wireframe reveals there is actually a vertice very close to the center of the light, and it is lighting the tri's circling it perfectly. Very clear in wirefame mode. :) |