identical shaders with different results?


(ratty redemption) #1

@cis, I understand most of that and thanks for posting the shader, although I`m still confused by this lines of yours:

so when looking at the surfacesprites in front of a hill, i can see schemes of what is behind the hill


(cis) #2

the sprites with ge128 are partialy transparent and when looking through the transparent parts, the texture of that posted shader is transparent also. those sprites work like xray glasses then :wink:


(ratty redemption) #3

so the ground becomes transparent, when seen through the transparent parts of the surface sprites? very weird.

sounds like you`ve got some radioactive grass growing there? :wink:

edit: could it be the depthwrite function thats playing up?


(cis) #4

maybe, only ydnar can answer that. i only know that the depthwrite is required for the surfacesprites. without it the “sorting” between sprites and main texture gets realy messed (overlapping each other).


(ratty redemption) #5

understood.


(ydnar) #6

SOF2 does some loose depth sorting of blended stuff, but that’s the only engine variant that does. This is what most games, including ET using masked instead of blended foliage.

y


(ratty redemption) #7

isnt masked faster to render then blended? ...so I guess we should use that for surface sprites if blended isnt needed for them?

and if our shaders in general have both alphafunc and blendfunc would that be slower then blended on it`s own?


(cis) #8

sounds like masked foliage is first choice. sof2 probably doesnt support that, does it? i do still struggle a bit with the surfacesprites as they look pretty ugly from a distance (on “low quality sufacesprites” setting in sof2, ugly is not enough to describe just how horrid they look from a distance). i’m up to a fadescale of 6 already. its on my list to try to improve how they look from a distance after im done fixing some other stuff. using g128 could help as those sprites look “fuller” with it but that causes this xray effect.