Page 1 of 1

PNG alpha ignored on linedefs

Posted: Tue Oct 30, 2007 16:01
by Nash
Example WAD http://nash.wanzafran.com/doomstuff/smoke.zip

I realize I used a sprite for the line's texture, but this problem happens with proper textures (TEXTUREx and TX_) too. The reason I'm re-using this WAD was because it was the quickest way for you to check out what I'm reporting.

I need it to achieve a bunch of visual effects on textures, but most importantly, I need it to spice up the lighting in my map by using PNG alpha to fake baked shadows, since GZDoom's lighting is pretty flat.

I used to achieve it by making tons of thin sectors in front of the walls (or around a construct) and gradually decreasing the sector brightness using transfer brightness so that actors don't get affected by the lighting, just the floors.

This method proved to be too much work, and will not look as intended with a current project I'm working on that is lit 100% by dynamic lights (no sector lighting).

Example image: http://nash.wanzafran.com/doomstuff/nsinv02.png

(again, needed to demonstrate it real quick, sorry for the big pic, it was an old screenie I posted in the WIP thread at ZDoom.org)

To recreate the above effect without using sector lighting, I'd setup a 3-d floor sector around the bench and use a gradually fading out PNG texture. It would also look a lot smoother than sector lighting. For walls, I'd just create long strips of 3-d floor sectors along the walls to apply the fake shadows.

I believe Doomsday does this automatically. A more elegant option would be true lightmaps but I don't see you implementing that anytime soon (and that's perfectly fine; don't get me wrong) so this is the best way I can think of without having to wait for further port developments.

If you can't fix this due to technical difficulties in the code, then can you suggest something else to me, this has to work without sector lighting.

(The last resort would be to simply create separate textures for the areas that need shadows but that'll take too much WAD space)

Posted: Tue Oct 30, 2007 16:21
by Nash
http://nash.wanzafran.com/doomstuff/sh3-shot.jpg

Here's a screenshot from one of the levels in Silent Hill 3 viewed from a map viewer.

This is a fullbright screenshot, as you can see most of the shadows have already been baked into the textures. I don't think it's a good idea to do it that way in Doom mods though (SH3 takes up about 2-3 gigs of space).

It would look very atmospheric once the in-game lights have been applied, but I'm not in a convenient situation to post a screenshot of that.

Just demonstrating what I'm trying to achieve.

Posted: Tue Oct 30, 2007 21:47
by Graf Zahl
It seems I forgot to flag these properly. For the time being just make the line translucent with an alpha of 254. That should give you what you need.

Posted: Tue Oct 30, 2007 23:09
by Nash
3-d floors with an alpha of less than 255 are not affected by dynamic lights. :(

(And I suspect linedefs are the same case)

Posted: Wed Oct 31, 2007 8:34
by Alter
Nash wrote:3-d floors with an alpha of less than 255 are not affected by dynamic lights. :(

(And I suspect linedefs are the same case)
Noticed that with my quake 2 inspired project..... it explains why it doesn't light my 3d floor at all

Posted: Wed Oct 31, 2007 9:46
by Graf Zahl
No, they aren't. I can't use lightmaps on them

Posted: Wed Oct 31, 2007 9:52
by Nash
Well, I'll have to use the last resort then. Separate textures for shadowed surfaces it is.

Posted: Thu Jan 31, 2008 10:55
by Graf Zahl
fixed