Jump to content
The Dark Mod Forums

Tracker 3881: Cubemap Lighting Beta


Recommended Posts

I like the sound of zone-based control.

 

My impression of the non-ambient cubicLight examples in the demo:

 

grate6 - works.

cubelightCube - nothing visible. Alpha channel problem?

cubesheen - nothing visible. In an image editor it does appear to have an alpha channel that's neither wholly black nor wholly white, as per Spooks's post above.

  • Like 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites
  • Replies 179
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

Based on Rebb's work to make the Ambient light run it's own light interaction rather than piggy-back on the main light interaction, I have made a patch that allows you to add the "cubicLight" token to

I don't have a lot to add, I have not downloaded the test map, but I tested with my own: I can see very glossy results with the industrial cubemap. No banding, tested with GLSL on and off. Here is the

I thought this would take ten minutes but I ended up spending a good while troubleshooting. Anyway, here is the lamp with a more accurate projection...     The colors are too saturated, details too s

Posted Images

I'll go back over the materials.

 

Rules:

 

1) ambientCubicLight = no alpha channel. Defaults to noshadows (I believe you can override with forceShadows)

 

2) cubicLight = must contain alpha. Looks for pointlight or projected designation in light entity.

 

3) (Both) cubemap = _NZ convention, cameraCubeMap = _up convention

  • Like 1

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

Ah, I can see something with cubesheen if I switch from omni to projected mode. Edit: also with cubelightCube.

 

cubelightCube projected onto a wall looks like this:

post-35144-0-69715900-1474907609_thumb.jpg

The edges of the projection are clipped in a way that changes abruptly as I move around.

Edited by VanishedOne
  • Like 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites

I've been disappointed in the lack of good cube map making programs out on the net, making new cube map generic lights is going to be harder than it should be unless you want to mess a lot with Photoshop and a 3D modelling program, which I don't. I've an idea about how I could make some in-TDM, since I'm not going to get to it any time soon I'll share it: You could make a cube/patch sphere with a dev grey texture and stand inside it, then put normal lights to illuminate the walls, then take an env_shot and you have a generic looking cube map.

 

I converted one of the lamp textures to a cube map some time ago but I've been busy and cba to make it look better. I wanted to just make it as an example of the improvement of a cubemap over regular lights, so I should probably post the example already.

 

kscwzNw.jpgTbpzB0z.jpg

 

The cubelight looks brighter because 1) it's shittily made as I said and 2) it's a bigger light radius. You can definitely see the improvement though.

  • Like 3

My FMs: The King of Diamonds (2016) | Visit my Mapbook thread sometimes! | Read my tutorial on Image-Based Lighting Workflows for TDM!

 

 

Link to post
Share on other sites
  • 2 weeks later...

Is this intended behaviour?

 

post-35144-0-47963400-1476049487_thumb.jpg

 

The ambient cubic light is strongly brightening the metallic and glassy surfaces (something to do with specularity?), whereas the ground (textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour_dirty) is barely visible where the 'sun' parallel light doesn't hit it. The ordinary lights/ambientlightnfo brightens the scene in general, with the lampost keeping its dark diffuse colouring.

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites

The specular is an environmental reflection as well. You can use the nospecular argument on the light entity to disable that.

 

It may be worthwhile to explore somehow removing\replacing that behavior but I think this may be better once I implement a way to

add arbitrary per-material "custom lights".

 

After playing with Biker's Caduceus map, I think I'm gonna recheck whether the "light affects backsides" is correct. I think the

use case means it should default there.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

nospecular does get rid of the glowing metal and windows. :smile: Though _color also seems to play a role: at ambient_world's default it's as though there's a fog over the scene (there's still a red tint on the windows) which is gone in brighter light (e.g. the statues even seem to get darker).

 

post-35144-0-74635400-1476056472_thumb.jpg

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites

I'll probably take one last crack at getting _color to work properly. As it currently stands, the shader takes

the color and uses it as a power factor to saturate the result of the previous operations. I'll try reverting back

to the magic number the shader shipped with and see if I can inject the color operation at another spot.

 

Per my previous comment, the backsides behavior is already properly set on the code side so no need to do work there at least.

  • Like 1

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites
  • 4 weeks later...

The colour indeed seems more controllable now. :)

 

Diffuse lighting for the ambient samples now remains pretty dark even at _white. (Whereas the non-ambient grate6 seems to be behaving like a normal light colour-wise.) For TDM's largely nocturnal settings that's not necessarily a huge problem, except that the same light then becomes very bright if enhanced ambient lighting is turned off. Specular lighting on the ambients, if left enabled, always has a powerful glow-in-the-dark look compared to diffuse, even at low _color.

 

Cubic ambient only, with specularity (the highlights on the wooden counter look pretty bad since the diffuse is so weak):

 

post-35144-0-08517300-1478545115_thumb.jpg

 

Comparison shot with the player lantern on:

 

post-35144-0-73788500-1478545457_thumb.jpg

 

Comparison shot with specularity off (note the mid-level light gem even though it's a very dark shot):

 

post-35144-0-80078000-1478546775_thumb.jpg

 

Cubic ambient (with specularity on) at _white, under enhanced and simple ambient settings (note the effect on the light gem too):

 

post-35144-0-07888100-1478546787_thumb.jpg

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites

The cubegrate6 projected light no longer works with these new glprogs. Can anyone else confirm?

 

edit: sorry, deleted some files on my end, it's there still.

 

Otherwise it definetely looks better now, but besides the Simple Rendering update VO mentioned, I find it weird how the interaction works with specular off. In addition, several of the prefab lights don't work, like cubegradient f.i.

Edited by Spooks

My FMs: The King of Diamonds (2016) | Visit my Mapbook thread sometimes! | Read my tutorial on Image-Based Lighting Workflows for TDM!

 

 

Link to post
Share on other sites

Well, the issue with the simple ambient is a universal one. If your ambient world has a complex light texture rather than a no falloff texture it won't match the simple ambient. If you use the cubic ambient as your ambient world light you'll need to decide how to mitigate that (eg. Custom materials with less ambient brightening, etc) or warn players that the mission only works with the Enhance Ambient mode.

 

I think the oddness of the specular highlighting can be improved by changing the light ceter location. It seems that the shader was designed with little HL2 style probes everywhere so a big world sized ambient is going to cause problems.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

I've checked against the previous glprogs and the new revision definitely produces a darker look in places: I've got walls of textures/darkmod/stone/brick/blocks_sandstone01_bluegrey that were fairly bright with a "_color" "1 1 1" cubesky in previous revisions, but are now pretty dark even when close to the light centre. (The price of improved _color handling?) But yes, I had forgotten to check falloff.

 

It looks as though the "falloff" spawnarg doesn't work here; are cubic nfo ambients impossible then?

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to post
Share on other sites
  • 3 weeks later...

I've checked against the previous glprogs and the new revision definitely produces a darker look in places: I've got walls of textures/darkmod/stone/brick/blocks_sandstone01_bluegrey that were fairly bright with a "_color" "1 1 1" cubesky in previous revisions, but are now pretty dark even when close to the light centre. (The price of improved _color handling?) But yes, I had forgotten to check falloff.

 

It looks as though the "falloff" spawnarg doesn't work here; are cubic nfo ambients impossible then?

 

The shader hard-codes spherical falloff for standard lights. For the cubic ambient, you need to add falloff 0 to the light entity for it to behave properly.

 

As for allowing a falloff texture? Someone with more ARB shader experience than me would need to add that feature.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

I've been disappointed in the lack of good cube map making programs out on the net, making new cube map generic lights is going to be harder than it should be unless you want to mess a lot with Photoshop and a 3D modelling program, which I don't. I've an idea about how I could make some in-TDM, since I'm not going to get to it any time soon I'll share it: You could make a cube/patch sphere with a dev grey texture and stand inside it, then put normal lights to illuminate the walls, then take an env_shot and you have a generic looking cube map.

 

I converted one of the lamp textures to a cube map some time ago but I've been busy and cba to make it look better. I wanted to just make it as an example of the improvement of a cubemap over regular lights, so I should probably post the example already.

 

kscwzNw.jpgTbpzB0z.jpg

 

The cubelight looks brighter because 1) it's shittily made as I said and 2) it's a bigger light radius. You can definitely see the improvement though.

 

Could you supply your latest textures for this? I'd like to tinker a bit and see if this can be a demo asset for 2.05.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

Here you are and the material definition:

lights.zip.txt

lights/cubic/tdm_lampshade_cubic
{

	cubicLight
	qer_editorimage		env/lights/test_up
	{
		forceHighQuality
		cameraCubeMap	env/lights/test
		colored
		zeroClamp
	}


}
  • Like 2

My FMs: The King of Diamonds (2016) | Visit my Mapbook thread sometimes! | Read my tutorial on Image-Based Lighting Workflows for TDM!

 

 

Link to post
Share on other sites

Hmm. Since falloff is not controllable other than sizing the light, the use of the scale keyword might help here.

 

1) Shrink the light radius a bit

2) Scale the projection texture up:

 

 

 
lights/cubic/tdm_lampshade_cubic
{

    cubicLight
    qer_editorimage        env/lights/test_up
    {
        forceHighQuality
        cameraCubeMap    env/lights/test
        scale 0.7, 0.7
        colored
        zeroClamp
    }


}
 
  • Like 1

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites
  • 4 months later...

I need somebody to check whether or not the current cubic light images have corrupted artifacts when in-game. Just make a light with lights/cubic/cubegrate6 as its texture and check if it looks corrupted in-game. Your Interaction Shader must be set to Enhanced. Either something went really bad in the last small update or some of my files are corrupted...

My FMs: The King of Diamonds (2016) | Visit my Mapbook thread sometimes! | Read my tutorial on Image-Based Lighting Workflows for TDM!

 

 

Link to post
Share on other sites

I did test spawning atdm:lamp_desk_cubic last night and it worked as expected.

 

I'll try testing the cubegrate6 texture tonight if I get a chance.

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to post
Share on other sites

Oh no. This looks like a more mild version of how the latest Nvidia drivers broke Sikkmod shaders.

 

What OS and driver version are you currently running?

 

(I'm currently on Windows 10 with the Creators Edition update and the latest hotfix drivers.)

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

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.

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