Design Efficiency???


(demoneye) #1

I posted this here, because I think Ydnar should be able to give me better feedback on the engine.

This is from RtCW…

This map has two wall build examples… The one on the left has shutters (detail) in front of caulk blocks (structural), and the rest of the wall (structural) has been built around these blocks.

I just want to check which method is better cause I’m getting some FPS issues? Surely the wall on the right – one solid wall (structural) with the shutters (detail) sitting on top of it – is much more efficient in terms of r_speeds!

Is the overdraw of textures (shutters in front of the brickwork) causing the engine more headaches, and thus reducing FPS?

DeMoNeye


(kat) #2

I’d go with the caulk block method as you’ll get pretty messing z-buffer problems otherwise.


(demoneye) #3

The detail “shutters” sit on the surface of the wall - 1 unit thick - so no z-fighting issues.

DeMoNeye


(pazur) #4

i would go for the overdraw method. less tris and quicker to build. if u dont have too much stuff that overdraws behind that building i think it`s ok.


(kat) #5

you’ve got a ‘drawn’ texture behind those shutters so you increase the chance of z-fighting (esp in 16 bit) regardless of the distance or surface flag (detail/structural) between the two.


(demoneye) #6

Thanks Kat - does the possibility of z-fighting, or the need for the engine to work out if it should not z-fight cause the FPS increase?

Pazur - l looked at using overdraw too… The trouble with that, is that the FPS hit was even higher, because the textures need to .tga and not .jpg, so increased file size resuilts!

DeMoNeye


(kat) #7

I don’t know if it does technically (I don’t know if anyones ever tried to measure it so to speak) but I have noticed as much in the stuff I’ve done and seen.

You could turn that blind texture into a decal, there’s a specific reference, ‘entity mergable’, in the decals shaders that added to the usual tcgen offset (??) may be a necessity for the shader to display correctly with skyportal fog… it depends though if you’re wanting the blinds to sit away from the surface like they currently are


(pazur) #8

the shutters in that example are “solid”(i mean no alpha)… so u could use jpg as well. as far as i know the engine just uncompresses them when loading into hunk. if u have a map layout like in mp_destruction where there is only a street with the fronts of houses and skybox behind it then this should be no problem. it looks different if u have a more complex layout… then the caulk method is deff better.


(SCDS_reyalP) #9

I would make the walls AND the shutters detail, and use one gigantic wall of structual caulk overlapping the wall.

You can get z-fighting even when the overdrawn texture is quite a few units a way. Decals do not completely avoid this either. Just look at ET in 16 bit mode to get about 10 million examples. If these pieces are not going to be seen from far away, it is less of an issue. Z-fighting, by itself doesn’t hurt frame rate, it just looks ugly. Drawing texture you don’t need (behind the shutters) does eat fill rate. Whether more triangles or more fillrate hurts you FPS depends on the system and the rest of the map. There is a command to measure overdraw, but I don’t recall the specifics offhand.

If you look at the caulk block example with r_showtris, and notice where the t-junctions make extra verticies, you will probably find that cutting your walls at various diagonals will give you lower r_speeds. That is another good reason to make all the textured stuff detail and back them with a single hunk of caulk.

Finally, you have another option. If you are willing to not have the shutters stick out, you can make a texture which combines the shutter and wall textures (a in a single tga or jpeg file) and this will have low r_speeds and no overdraw. It may use more texture memory though.