3D weapon model SSAO

Moderator: GZDoom Developers

Post Reply
User avatar
Nash
 
 
Posts: 17433
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

3D weapon model SSAO

Post by Nash »

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.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49056
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: 3D weapon model SSAO

Post by Graf Zahl »

This isn't really surprising because the HUD models are an overlay and not part of the scene itself.
dpJudas
 
 
Posts: 3037
Joined: Sat May 28, 2016 1:01 pm

Re: 3D weapon model SSAO

Post by dpJudas »

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.
skornedemon
Posts: 154
Joined: Mon Aug 02, 2010 11:10 am

Re: 3D weapon model SSAO

Post by skornedemon »

You could also just bake AO onto the model's texture.
User avatar
Rachael
Posts: 13530
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: 3D weapon model SSAO

Post by Rachael »

That's not really a solution, especially since HUD models are animated. That simply will not work.
skornedemon
Posts: 154
Joined: Mon Aug 02, 2010 11:10 am

Re: 3D weapon model SSAO

Post by skornedemon »

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.
User avatar
Nash
 
 
Posts: 17433
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: 3D weapon model SSAO

Post by Nash »

Static, baked AO defeats the point of real time screen space ambient occlusion... :P
User avatar
Rachael
Posts: 13530
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: 3D weapon model SSAO

Post by Rachael »

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

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.
skornedemon
Posts: 154
Joined: Mon Aug 02, 2010 11:10 am

Re: 3D weapon model SSAO

Post by skornedemon »

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.
User avatar
Rachael
Posts: 13530
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: 3D weapon model SSAO

Post by Rachael »

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

Return to “Closed Feature Suggestions [GZDoom]”