3D weapon model SSAO
Moderator: GZDoom Developers
3D weapon model SSAO
It seems 3D HUD weapon models do not have any SSAO applied (not sure if forgotten or bug).
Can be tested with a mod that uses 3D models for everything like Enjay's Gene Tech.
Can be tested with a mod that uses 3D models for everything like Enjay's Gene Tech.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: 3D weapon model SSAO
This isn't really surprising because the HUD models are an overlay and not part of the scene itself.
Re: 3D weapon model SSAO
As Graf mentions this is because it is drawn on top of the scene. Because we clear the zbuffer it requires an extra SSAO pass to do this. As this pass is very expensive, the costs are IMO too big.
We could avoid this by using glDepthRange: split zbuffer in two, some for the scene and some for the weapon. That allows us to draw the weapon as part of the opaque pass, but this will only work if we got no translucent parts in weapons. Otherwise it becomes a two step operation to draw the weapon (more work required).
Btw., I think the normals in the GeneTech models are broken. At least the light on the models there seem far more flat than I'd expect.
We could avoid this by using glDepthRange: split zbuffer in two, some for the scene and some for the weapon. That allows us to draw the weapon as part of the opaque pass, but this will only work if we got no translucent parts in weapons. Otherwise it becomes a two step operation to draw the weapon (more work required).
Btw., I think the normals in the GeneTech models are broken. At least the light on the models there seem far more flat than I'd expect.
-
- Posts: 154
- Joined: Mon Aug 02, 2010 11:10 am
Re: 3D weapon model SSAO
You could also just bake AO onto the model's texture.
Re: 3D weapon model SSAO
That's not really a solution, especially since HUD models are animated. That simply will not work.
-
- Posts: 154
- Joined: Mon Aug 02, 2010 11:10 am
Re: 3D weapon model SSAO
Simply move the model in whatever program you use so nothing is 'in the way' of a general AO pass(arms against something,fingers holding onto something,etc).
This is about as good as it'll get I think unless major rewrites happen.
This is about as good as it'll get I think unless major rewrites happen.
Re: 3D weapon model SSAO
Static, baked AO defeats the point of real time screen space ambient occlusion... :P
Re: 3D weapon model SSAO
Unless you are offering real solutions to problems presented in the feature suggestions (and actually have an understanding about what the feature suggestion thread is all about, and the motivations behind it) please don't bother with them.skornedemon wrote:Simply move the model in whatever program you use so nothing is 'in the way' of a general AO pass(arms against something,fingers holding onto something,etc).
This is about as good as it'll get I think unless major rewrites happen.
The thing is - anyone who's been modding GZDoom long enough, and using models for long enough, already knows about the "baked AO" trick. This post offers absolutely nothing of real value, and defeats the purpose of making the thread to start with. This thread was created because the OP did not want to do the baked AO trick anymore.
Your post is not only unhelpful, but annoying, at least to those who want this feature.
I'll quote a post Graf made almost exactly 7 years ago about this very problem:
Graf Zahl wrote:I wouldn't add this to the first post but it needs to be said here, too:
If you want to suggest a workaround for a requested feature please think first if your workaround meets the suggester's needs. I have seen it too many times that some people post stuff that completely ignores the original post's motivation or suggests some laborious things that would be more an annoyance than anything else to do repeatedly. Often these things come equipped with the word 'just' as if it was the most normal thing to do repeated cumbersome routines.
Such posts tend to create tension because the OP might feel ignored on purpose by that. Here's a good example of this kind of behavior which I really don't want to see anymore on the Feature Suggestions forum.
-
- Posts: 154
- Joined: Mon Aug 02, 2010 11:10 am
Re: 3D weapon model SSAO
While I think that was just a TAD harsh, I didn't mean it as a replacement for your feature suggestion.
If you didn't know about the baked AO,now you do - was what was going on in my mind.
In terms of a feature, I would love actual real time SSAO! Apologies for the misunderstanding.
If you didn't know about the baked AO,now you do - was what was going on in my mind.
In terms of a feature, I would love actual real time SSAO! Apologies for the misunderstanding.
Re: 3D weapon model SSAO
It's not my intent to be harsh and I am sorry if I came off that way. I know you were trying to be helpful but in the future please try and consider what the suggestion is actually asking for.
Nash is an exceptionally experienced and potent modder - he probably would not come to the feature request forum if he hasn't already investigated every possible way he could accomplish what he is trying to do - and you'll see that with some of his posts in the Editing forum asking if this or that are possible. He also isn't the only one who does this.
In this particular case, true SSAO for weapons is a lot more flexible and easier for him to work with - which is why he's put the request here. And, again - he's not the only one who does this.
Nash is an exceptionally experienced and potent modder - he probably would not come to the feature request forum if he hasn't already investigated every possible way he could accomplish what he is trying to do - and you'll see that with some of his posts in the Editing forum asking if this or that are possible. He also isn't the only one who does this.
In this particular case, true SSAO for weapons is a lot more flexible and easier for him to work with - which is why he's put the request here. And, again - he's not the only one who does this.