Shadowmaps for GZDoom (can be tested in QZDoom now)
Moderator: GZDoom Developers
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Another try: Copy and paste the exact same light from the testmap do my map, made the sectors light level 0, made sure the lines are 1-sided and solid
Same issue. When I warp to MAP01 it works perfect in the test map.
Additionally made a complete new test room in C2M5 with only the light and two columns, doesn't work as well. Made an own testmap with BoA resources with one room and a light source and it worked perfect. Question: Do these shadow maps have limits? For example if the map is too large?
Same issue. When I warp to MAP01 it works perfect in the test map.
Additionally made a complete new test room in C2M5 with only the light and two columns, doesn't work as well. Made an own testmap with BoA resources with one room and a light source and it worked perfect. Question: Do these shadow maps have limits? For example if the map is too large?
Last edited by Tormentor667 on Sun Mar 12, 2017 5:42 am, edited 1 time in total.
-
-
- Posts: 17465
- Joined: Mon Oct 27, 2003 12:07 am
- Location: Kuala Lumpur, Malaysia
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
That light's radius might not be big enough to cast shadows. To visualize where shadows will be cast, look at the radius wireframe in GZDB. Imagine that circle as where all the surface will be painted white. Then you place blocking 1-sided lines in that radius to "block" the light.
Also try raising the Z height of the light to be higher.
Also try raising the Z height of the light to be higher.
-
- Posts: 13782
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Attenuated lights add realism to the scene. They use a more realistic falloff formula than normal lights do. They should be an additional set of lights in GZDoomBuilder you can use, and also they are available in GLDefs as well.
They should not affect your shadowmaps. As I said I think the problem is your obstacle is too small for the ray test.
They should not affect your shadowmaps. As I said I think the problem is your obstacle is too small for the ray test.
You do not have the required permissions to view the files attached to this post.
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Doing the same situation in a new map on BoA resources, I simply think that the system can't handle large maps as in Boa ...
So it actually DOES work with these setup but not in my live map... maybe I have something overridden with defaultmap?
Exactly same room placed in C2M5
So it actually DOES work with these setup but not in my live map... maybe I have something overridden with defaultmap?
Exactly same room placed in C2M5
-
- Posts: 13782
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Tormentor: For the 4th time I don't keep saying this so that you and Nash can keep ignoring me. Your obstacles in C2M5 are too small.
Okay, seeing the second picture, yes, there's a definite problem. That does seem to be a bug, and you may be right in your theory about map size.
Okay, seeing the second picture, yes, there's a definite problem. That does seem to be a bug, and you may be right in your theory about map size.
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Notived it already the 1st time and tried to enlarge it to 80x32 units, that didn't change anything - but yes, the 2 screenshots are obviousRachael wrote:Tormentor: For the 4th time I don't keep saying this so that you and Nash can keep ignoring me. Your obstacles in C2M5 are too small.
-
- Posts: 13782
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Can you send me a copy of that map, with the extra room added please? Your BOA git is very big.
-
-
- Posts: 17933
- Joined: Fri Jul 06, 2007 3:22 pm
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
There's a limit of 1024 light sources. If your map is large enough to have already over 1024 light sources, some of them won't work.
I had suggested to dpJudas to check for player viewpoint proximity. People won't really notice if the light isn't culled by a pillar that like 2000 units away from the player.
I had suggested to dpJudas to check for player viewpoint proximity. People won't really notice if the light isn't culled by a pillar that like 2000 units away from the player.
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
It's map C2M5.WAD at the Git, if that helpsRachael wrote:Can you send me a copy of that map, with the extra room added please? Your BOA git is very big.
I guess that could be the problem, but after searching for all light objects in C2M5, I only found 593 (no monsters are added yet). Beyond in C1M1 the demo room works perfect, where I only counted 66 light sources. I think the viewpoint proximity addition would be the right approach.Gez wrote:There's a limit of 1024 light sources. If your map is large enough to have already over 1024 light sources, some of them won't work.
I had suggested to dpJudas to check for player viewpoint proximity. People won't really notice if the light isn't culled by a pillar that like 2000 units away from the player.
-
-
- Posts: 3132
- Joined: Sat May 28, 2016 1:01 pm
Re: QZDoom - ZDoom with True-Color (Version 1.2.2 released!)
First of all, I didn't make this feature for you. I wanted to play with ray tests, then saw a simple opportunity to generalize it as a small contribution to GZDoom. Secondly, the heavy part of this pass currently is the way I'm doing soft shadows - that code isn't too far to how you do nice soft shadows in modern games either. Strangely enough, running the latest Battlefield on a 2013 video card with high quality shadows runs like shit too. And last, I don't really care how it runs on a 2013 card. I don't own one of those. What do you think a NV 980 user will say when you say your 2013 card can't run the latest Battlefield on max settings?ZZYZX wrote:It's just that you essentially made something that has all the limitations of Doom3 stencil shadows (as in it doesn't work with non-solid geometry), and on top of that requires a 2013 videocard to not lag horribly.
As for the limitations, yes, 1D shadowmaps are not as feature rich as 2D shadowmaps. Let me ask you a simple question - if you could choose between no shadows under actors, or the simple sprite shadow dot that games like UT 99 used, which one would it be? Because you're under the illusion that your choice is actually between my patch and a full featured shadowmap implementation. It is not.
I merged it into QZDoom master because the feature was working as I intended and I wanted to see if it gave any problems before PR'ing it up against GZDoom. If you don't like the effect, then don't enable it! If you have a 2013 card, then improve the GLSL, or don't enable it. If you write a full lightmap implementation that makes better light, then we will delete my code and replace it with yours.ZZYZX wrote:Again, here I'm assuming that if you merged it from your dev branch to the master branch and said "test it", then you think it's done enough...
If it's not, then I'm sorry for the reaction and you should have said that it's 10% done instead of "go and test it".
Why don't you implement it then? I never signed up for that.ZZYZX wrote:Also: isn't classic shadowmapping dumb and very straightforward to implement?
-
-
- Posts: 3132
- Joined: Sat May 28, 2016 1:01 pm
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Probably a good way of doing it. I just need a good easy way of taking portals into account when doing it. Maybe something like check if a portal line is in sight, then repeat the test on other side of portal as well.Gez wrote:I had suggested to dpJudas to check for player viewpoint proximity. People won't really notice if the light isn't culled by a pillar that like 2000 units away from the player.
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: QZDoom - ZDoom with True-Color (Version 1.2.2 released!)
My thought, and to be honest dpJudas, I really appreciate all the additions you made to the renderer lately - ambient occlusion, tonemaps, all that fancy stuff - this really enhances the engine a lot. Same goes to the shadows. It is limited, yes, but so is Doom!dpJudas wrote:First of all, I didn't make this feature for you.ZZYZX wrote:It's just that you essentially made something that has all the limitations of Doom3 stencil shadows (as in it doesn't work with non-solid geometry), and on top of that requires a 2013 videocard to not lag horribly.
-
-
- Posts: 3132
- Joined: Sat May 28, 2016 1:01 pm
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Thanks, Tormentor. For what it is worth, I'm not questioning that also having true shadow maps in GZDoom would be really cool - I'm just saying this feature was never intended to be that. They are entirely out of scope for what this pass is trying to do.
-
- Posts: 13782
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
You are probably too used to hearing me say this by now, but I am thankful for *all* the additions you've done - both in Software and OpenGL. This is the coolest toy I've played with since I first stumbled upon ZDoom, itself, right alongside with when Graf first added the current DECORATE parser, and it seems like every month it is only getting better.
(P.S. where were you 10 years ago?! rofl)
(P.S. where were you 10 years ago?! rofl)
-
-
- Posts: 3132
- Joined: Sat May 28, 2016 1:01 pm
Re: Shadowmaps for GZDoom (can be tested in QZDoom now)
Busy playing WoW, of course. Like Romero and everyone else.Rachael wrote:(P.S. where were you 10 years ago?! rofl)