View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004683 | The Dark Mod | Graphics | public | 25.11.2017 14:55 | 02.12.2017 08:25 |
Reporter | Spooks | Assigned To | duzenko | ||
Priority | normal | Severity | normal | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
OS | Windows | OS Version | 7 | ||
Product Version | SVN | ||||
Fixed in Version | TDM 2.06 | ||||
Summary | 0004683: ambientCubicLights have no falloff | ||||
Description | The abmientCubicLight light types have no falloff and appear glitched in 2.06. This problem does not affect the cubicLight lights. A screenshot of the problem and a testmap could be found in this post: http://forums.thedarkmod.com/topic/18282-tracker-3881-cubemap-lighting-beta/?p=414721 | ||||
Additional Information | My videocard is an nVidia GTX 950 running driver version 388.31 -- context which I feel is important. | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
The falloff texture slot is being used for ambient specular component. How do you pass the falloff texture in light material? That link only has the .map file. |
|
As far as I know, when cubemap lights were introduced they were an import of Sikkpin's shader and came with (preprogrammed?) spherical falloff - I don't think they have a falloff texture. I don't wish to mince terms here, to be fair I don't know if falloff or lack thereof is the exact cause of this graphical artifact. It's the best word I could use to describe the clipping behavior the lights exhibit when viewed by the player. I've seen a graphical glitch like this in earlier versions of TDM and from what I remember the cause was the vertex/fragment programs. Vague, I know, but I hardly know the math behind those. |
|
I gave it some thought and I kinda need a mapper to decide here for me. Do we need falloff at all for ambient lights (even cubic)? Do we want shader-level spherical falloff for cubic ambient light? Do we want shader-level falloff to be linear, quadratic or XXX? At this point I would prefer it over adding another texture. The clipping here is a result of the scissor optimization, that clips screen space based on rough estimation of the light bounding box. |
|
The current "2D projection + 1D falloff image" method affects ambient lights the same as normal lights. I did a quick test and an ambient light with the same projection texture does look different with and w/o a falloff. Removing that would affect how already released missions look (and possibly even play) in a negative way, so yes, we need it. A caveat: most common ambient lights in TDM use their 2D projection texture as their 1D falloff texture through the "lightFalloffImage makeIntensity( tex )" keyword. I don't know how that factors into memory usage, but I mention it if you are concerned about footprint. As far as cubic ambient lights are concerned, I really cannot say. In my opinion they are, at this point, not that useful to mappers until a system is built around them, so that a mapper can utilize cubemaps (or irradiance maps, now) in environments of any size, shape, or form. Much like a normal ambient light "leaking" through walls, ambient cubic lights will show cubemaps through walls, which looks very jarring. Normal cubic lights (eg cubegrate6, tdm_lampshade_cubic) have had spherical falloff so far, which I find agreeable. I am a fan of quadratic, but that usually means a larger light radius to compensate for the exponential function, which in turn means more shadow draws and worse performance. The problem here is I cannot imagine anything BUT a shader-level falloff implementation for cubic lights. If you would offer an example of how a texture - be it a 1 pixel strip or a 2D one - would factor into a cubemap's falloff, I'd love to hear it. The easy bit about our current lights is that the 2D light textures, for the most part, act as the attenuation for the light, but that just doesn't fly with cubic lights. e: As this is a dialogue at present, I'd like another mapper with experience with falloff and light properties to chip in. I'm working off a lot of hypotheticals, because cubic lights have not seen wide use yet and do not have much light texture assets associated with them. |
|
At revision: 15102 | |
Date Modified | Username | Field | Change |
---|---|---|---|
25.11.2017 14:55 | Spooks | New Issue | |
25.11.2017 14:55 | Spooks | File Added: broken cubic light.jpg | |
25.11.2017 15:08 | duzenko | Note Added: 0009700 | |
25.11.2017 15:17 | Spooks | Note Added: 0009702 | |
29.11.2017 09:04 | duzenko | Assigned To | => duzenko |
29.11.2017 09:04 | duzenko | Status | new => assigned |
01.12.2017 21:20 | duzenko | Note Added: 0009721 | |
01.12.2017 21:21 | duzenko | Note Edited: 0009721 | |
02.12.2017 00:21 | Spooks | Note Added: 0009723 | |
02.12.2017 00:25 | Spooks | Note Edited: 0009723 | |
02.12.2017 08:25 | duzenko | Note Added: 0009724 | |
02.12.2017 08:25 | duzenko | Status | assigned => resolved |
02.12.2017 08:25 | duzenko | Fixed in Version | => TDM 2.06 |
02.12.2017 08:25 | duzenko | Resolution | open => fixed |