PDA

View Full Version : Shadow only negative light trick doesn't work any more?



alexoctagon2009
11-28-2014, 02:20 AM
Hi

To get shadows without lights I used to make a light black, make the intensity a negative value, and make the shadow white, and this would cast a shadow from an object without any light. This was great to either enhance shadows or create new ones that weren't where you wanted them to be without affecting the lighting of the objects.

However, I've just tried this is LW11 and it doesn't work, has anyone else noticed this?

Cheers,
Alex

stiff paper
11-28-2014, 07:36 AM
Huh. Yes, that no longer seems to work in 11. It doesn't even work using the Classic Camera.

To be fair, that trick does date from the year 1743, when PCs were powered by oxen and weren't fast enough to allow the use of ray traced shadows, and so you'd use a doubled -/+ shadow mapped spotlight to give you a good quality shadow on, say, a character standing in the middle of a large field.

Can't think of any good reason these days for using this trick. Enlighten me? (Ba-dum-tsch! Actually, no pun intended... but, hey, I'll take what I can get...)

jeric_synergy
11-28-2014, 11:17 AM
Now I think you'd just EXCLUDE the light.

3DGFXStudios
11-28-2014, 12:06 PM
I used negative lights in a job a few weeks ago to get a dark corner and that worked great! LW11.6

stiff paper
11-28-2014, 01:07 PM
Sooo...

Tested it, commented, went out. Driving for two minutes and thought "Ack! Forgot to turn off shadows on the second light!"

Just got back. Tried it. It still works just fine, like it always has before. Oh. And also? I'm an idiot.

stiff paper
11-28-2014, 01:24 PM
Explaining an antique CG trick for 3DGFXStudios ('cos, you never know... maybe civilization will end and we'll have to go back to PCs powered by buffalo dung...) This is boring. Don't read if you don't like being bored. Do read if you're curious as to what we were talking about.

There didn't used to be any ray traced lights, only shadow mapped. If you lit a large area, like, say, a field, and set your shadow map to 256 by 256 (no memory back then!) then if you put a character in the middle of the field, one pixel of shadow in the shadow map would be much bigger than your actual character. Ugly. Really, very ugly.

What you used to do was parent another spotlight to the character's root null, in the same orientation as your "Sun" but closer to the character, and with the 256 by 256 resolution just big enough to cover the character's shadow. Then you'd clone that spotlight, leave its value the same but make it negative, and make it not cast shadows. The first new spot would light up the character and the ground around it, then the second one would subtract the exact same amount of light, leaving everything like it was originally, except you'd also be subtracting the negative light from the shadow cast by the first light. All you'd be left with is a mysterious high res shadow mapped shadow, but no extra illumination.

As I said above... nobody has used this trick for 237 years.

jeric_synergy
11-28-2014, 02:33 PM
The explanation still makes my brain sweat.

Cageman
11-29-2014, 07:30 PM
Using negative light to remove light from areas is quite usefull. Sad to see though that the art of lighting tends to be measured with checking GI on/off these days, because "everything" needs that photoreal look. :D

Sensei
11-30-2014, 05:20 AM
To get shadows without lights I used to make a light black, make the intensity a negative value, and make the shadow white, and this would cast a shadow from an object without any light. This was great to either enhance shadows or create new ones that weren't where you wanted them to be without affecting the lighting of the objects.


This way you have twice as needed render time. First light is illuminating spot, second light is canceling it out.

There are now much more efficient ways. See video tutorial:
https://www.youtube.com/watch?v=8vXIwUyrupo

Sensei
11-30-2014, 05:32 AM
Just got back. Tried it. It still works just fine, like it always has before.

And it will be working in any renderer, until somebody will put intensity=max(intensity,0) in light properties GUI handling code/renderer..

alexoctagon2009
12-01-2014, 05:33 AM
Thanks everyone, some of those ways do make my head hurt.

Just to re-iterate, I'm not looking for a negative light, as this is just sucking out light in a spherical area from the light and isn't defined enough shape for what I want.

What I'd like is to do is add a "shadow only light", to paint in some extra custom shadows, for the same artistic reasons as you'd use a negative light . The old way I've described above with one light worked perfectly and the increased render time was just an extra light's worth. (If you have say LW9, try it, you'll see what I mean)

I can of course do this as a separate pass but it creates extra processes and I cant see how its looking in my scene. Render time isn't a problem.

Any other thoughts?

stiff paper
12-01-2014, 08:20 AM
Any other thoughts?
Well, only the full description in my post above that outlines exactly how to do it in a way that still works. If you don't want to use shadow maps, then just use ray traced shadows.

Hieron
12-01-2014, 02:34 PM
Still works, but only with distant light type it seems.