Jump to content
The Dark Mod Forums

decal overkill?


ungoliant

Recommended Posts

performance issues are starting to gnaw at my brain. the following SS has about 65 ivy decals / models on the visible section of this wall. They are all visible from both sides (which is unnecessary and i'd like to fix that).

 

 

decalsmuch.jpg

 

I wonder 2 things:

 

does this look like crap?

 

if i plaster my whole mansion (pretty largish) in this way, is it likely to run most computers into the ground?

 

if either of these is true, is there a better looking / more efficient way to decorate than just spamming patches with decal textures everywhere?

 

where i haven't actually completed a full fm yet, i'm not sure how much detail i can get away with in a single visleaf, and i'd hate to do another 5 hours work for nothing trying to make this thing look good.

Edited by ungoliant
Link to comment
Share on other sites

Well first things first. Have you properly visportaled it?

play your map, go to this exact same area and go to console and type in r_showtris 2 and take a shot and post it.

 

If the building is in a big empty box well it's no wonder it lags.

 

Also: No, it looks good.

 

And furthermore: where's all the decals located?

Link to comment
Share on other sites

Decalwork looks quite good, actually - love the way the vines are combined. It is, ah, the too clean brick textures I have a slight problem with. ;) Not even a newly build mansion would look so sterile.

Come the time of peril, did the ground gape, and did the dead rest unquiet 'gainst us. Our bands of iron and hammers of stone prevailed not, and some did doubt the Builder's plan. But the seals held strong, and the few did triumph, and the doubters were lain into the foundations of the new sanctum. -- Collected letters of the Smith-in-Exile, Civitas Approved

Link to comment
Share on other sites

Well first things first. Have you properly visportaled it?

play your map, go to this exact same area and go to console and type in r_showtris 2 and take a shot and post it.

 

If the building is in a big empty box well it's no wonder it lags.

 

Also: No, it looks good.

 

And furthermore: where's all the decals located?

 

tris.jpg

 

for the most part, the building interior is indeed empty, however all the rooms inside are completely sealed off with no leaks, so the only thing that should be rendering at that spot is the exterior of the mansion and surrounding walls / skybox (which at this moment is all 1 visleaf, but apart from the mansion wing shown, is completely undecorated or cut up into more towers).

 

there are about 9 total decal textures used that are all located in textures/darkmod/decals/vegetation

 

edit: melan, i do intend to dirty it up a lot, and do some beveling, among other finish work, but thus far i have only been working with the vegetation decals. in fact, theres tons of decorative work i'd love to do here if performance issues don't end up getting in the way. I worry because geometry of this mansion wing is made up of ~900-1000 brushes, ~550 patches, minus however much the skybox takes up.

Edited by ungoliant
Link to comment
Share on other sites

that looks great! I think even if you'll have problems you could separate the mansion front/side/back/otherside by some additional mapping, using high hedges, garden walls, whatever.

 

If something could be optimised at the moment i think its the rack like thing the vine climbs on. With a custom normaled texture/ maybe alphamapped.. it could look just as great.

Edited by _Atti_
Link to comment
Share on other sites

that looks great! I think even if you'll have problems you could separate the mansion front/side/back/otherside by some additional mapping, using high hedges, garden walls, whatever.

 

If something could be optimised at the moment i think its the rack like thing the vine climbs on. With a custom normaled texture/ maybe alphamapped.. it could look just as great.

 

Yeah, also the bent columns could probably lose half their polygons and still look as good. Also, maybe you can set the racks to non-solid? (They probably are func statics already?) Another thing to watch out for is if you have func_statics, you can turn their never-visible faces to caulc (like the bottom side of a block sitting on the floor, or the wall side of a block that touches a wall). For brushes, D3 removes these automatically, but for func_statics they sit there and waste collision and shadow computation.

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

 

"Remember: If the game lets you do it, it's not cheating." -- Xarax

Link to comment
Share on other sites

As Tels said, those columns are far too high-poly. You can only get away with stuff like that if it's not casting shadows or unlit.

 

The racks should be done with textures if possible (or at least everything inside the outer frame like this - http://www.turbosqui....cfm/ID/220686), and the curve above the top-left/right windows seems too high-poly too.

 

65 decal patches is excessive, so you'd want to make your own vine textures in the correct shape if possible. The vines in that first screen could be done with nearer 6 patches this way.

 

Save a new map and try deleting all that to see if it makes a difference.

Edited by Stardog
Link to comment
Share on other sites

The decals are fine, there are loads of places where 50 odd are used in the training mission and I'd imagine similar numbers on Heart.

 

The trellis brushes should be a texture (I can make a white wooden one ?).

If they are brushes or even func static'd, if they are placed within a light volume, even if there is no visible lighting it will cause a lot of pain for people with weaker CPUs.

Might also want to keep an eye on the fencing above the entrance - tho generally the models behave fine with lighting compared to brushes/statics.

Link to comment
Share on other sites

thanks for the feedback guys.

 

regarding the rack/trellis/lattice, yes it would seem a texture would work better here, but using brushes it literally took about 2 minutes to make, and i wanted to see what it would look like. @Tels yeah its a func_static with noshadows 1 set, and the sides that should not be visible to player were painted nodraw, not caulk. not sure if thats any better. @Serp yes the lack of white wood textures in stock was somewhat dissapointing. If you do want to make one thatd be sweeeet.

 

regarding the columns, i used a very dense cylinder to create these, but to make matters worse, i shortcutted the ivy decaling on it by cloning them (twice each!), and adding 2 of the larger ivy decals stretched to fit the patches. :blush: perhaps it would be better to do it the old fashioned way.

 

regarding the decals themselves, like i was saying those 65 patches were only the ones in the visible area of the first SS, and that area wasn't even done yet. I'd estimate this front wall would have roughly 200-230 ivy decals before its finished by doing it this way.

 

65 decal patches is excessive, so you'd want to make your own vine textures in the correct shape if possible. The vines in that first screen could be done with nearer 6 patches this way.

 

hmmm that sounds like it would work, like for instance, one giant patch stretched to fit around the circular part of one of the towers, then a couple more to cover the flat parts of the walls.

 

is this the best way? because i got noooo idea how to texture things, (but i'd like to learn, and this sounds like a good excuse to do it). if i did, it sounds like itd be a total pain to align things together and avoid things like covering up all the windows on accident.

Link to comment
Share on other sites

It would be quite simple to do really:

  • Go to the decal in DR, find it in the media browser
  • Right click it, open the def
  • Open your text editor and paste this in
  • Go to your darkmod folder, find the pk4 tdm_textures_decals01 and open it in winrar or whatever.
  • Copy out the textures from both the dds folder (these are the diffuse colour ones, important) and the textures from the texture folder (the tga_local ones are the normal maps)
  • Dump them into a folder somewhere for easy access
  • Open photoshop or whatever, make a new canvas that is power of two, so 1024x2048 or something
  • -> If you are going to use the normals from the _local files it gets quite tricky, I wouldnt bother its easier to make your own off the diffuse
  • Start copy and pasting the diffuse layers in and moving them around to however you want.
  • ->Do the whole saving as the correct format etc,if you didnt use the normals, go generate one to test - check the wiki on best methods else I can help if you make the diffuse. You need to save. Remember you need to save as DDS(with alpha/transparency), check the wiki for info.
  • Edit your material script from earlier to reflect the new material, changed paths and names etc - it was just there as a template
  • Reload shaders in DR and hopefully it adds your new material - Add it then test in TDM.

Link to comment
Share on other sites

Are the lights your using shadow casting? If so try removing all your lights except for your one ambient light and check your FPS. If the FPS is good then you know its the shadows.

 

One thing you will need to look out for is the poly count. Right now you got this nice building but no surroundings so assuming you dont want to have a crappy environment for your beautiful building you will have to sacrifice those trellis and grates/railings above the entrance and replaced with a texture.

 

But The doom3 engine works with polies great so I'm thinking it's probably a problem with shadows.

Link to comment
Share on other sites

Are the lights your using shadow casting? If so try removing all your lights except for your one ambient light and check your FPS. If the FPS is good then you know its the shadows.

 

One thing you will need to look out for is the poly count. Right now you got this nice building but no surroundings so assuming you dont want to have a crappy environment for your beautiful building you will have to sacrifice those trellis and grates/railings above the entrance and replaced with a texture.

 

But The doom3 engine works with polies great so I'm thinking it's probably a problem with shadows.

 

yes the floodlights and streetlamps cast shadows, in fact i did it that way on purpose because the shadows cast on the walls accentuate the fact that my mansion exterior is not a bunch of flat surfaces, but is in fact 3d. the circular tower parts actually get thicker on the higher floors as the trim builds up, and some of the colored bands that encompass the building are indented inwards, and the windows have actually been cut into the walls and are not just textured slices of the exterior. the shadows make this show (i like my work to be appreciated :rolleyes:)

 

removing all lightsources except ambient_world yields about a 5 fps boost, for a total of 25-30 fps, where it was 19-25 before. as a comparison, in HoLS, my lowest framerate was at the entrance in the 'private sector' and ran 15-19 fps.

 

keep in mind, only one wing of my mansion is ~finished, and when walking outside the player will always be able to see at least 2 sides (unless i block it out somehow, and i dont really want to). Additionally i can't see a way to block out ANY of the roof portion of the mansion as the whole thing is crazy high steeple towers from front to back. Only 3 tower roof areas have been raised up thus far on the front side of the mansion.

 

as an update, after removing the 2 off-white lattice fences the ivy grows on, the dense cylinder columns and their 4 ivy decal clones, all the black iron fencing on top of the front awning thingy, and reducing all the horizontal patch tessellation of the upstairs tower trim (there were 9 pieces on each tower above the windows that had subdivisions of 12x3, reduced to 3x3), amazingly the FPS went from 25-30 fps to only a constant 30 fps.... i really thought itd be more than that. hmmm....

Link to comment
Share on other sites

yes the floodlights and streetlamps cast shadows, in fact i did it that way on purpose because the shadows cast on the walls accentuate the fact that my mansion exterior is not a bunch of flat surfaces, but is in fact 3d. the circular tower parts actually get thicker on the higher floors as the trim builds up, and some of the colored bands that encompass the building are indented inwards, and the windows have actually been cut into the walls and are not just textured slices of the exterior. the shadows make this show (i like my work to be appreciated :rolleyes:)

 

Trust me, we do, too :)

 

...reduced to 3x3), amazingly the FPS went from 25-30 fps to only a constant 30 fps.... i really thought itd be more than that. hmmm....

 

Hm, maybe you have fsync on and it is exactly 1/2 60 FPS? (But then, you'd never get 25 :)

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

 

"Remember: If the game lets you do it, it's not cheating." -- Xarax

Link to comment
Share on other sites

Serpentine, it definitely sounds like a polygon issue. Unfortunately you may have too much details :P

I've encountered this before and it's a bitch to fix. One area in particular I can recall I spent about a month going back and thinking of ways to optimize the brushes. Eventually I managed to bring 18 fps to 30.

 

There's things you can do to optimize the map which no player will notice. For example:

The top part has a lot of polies. Create a brush instead and cut a couple angles so it looks somewhat circular. If you line up the textures the player will probably not notice it's a brush instead of a patch.

Green part can be replaced with a texture of a railing. It wont look as nice up close but which would you rather have, more fps or a nice railing?

The purple outlined trim could be converted into a brush, it wont look as nice but only if you get close again.

The pillars should be much lower poly than that. Players will have a hard time noticing if it isn't perfectly rounded.

tris.jpg

Link to comment
Share on other sites

did you read my last post all the way through?

 

after removing the 2 off-white lattice fences the ivy grows on, the dense cylinder columns and their 4 ivy decal clones, all the black iron fencing on top of the front awning thingy, and reducing all the horizontal patch tessellation of the upstairs tower trim (there were 9 pieces on each tower above the windows that had subdivisions of 12x3, reduced to 3x3), amazingly the FPS went from 25-30 fps to only a constant 30 fps.... i really thought itd be more than that. hmmm....

 

all the areas except purple including the fence area, including the lights, i deleted and then ran. it capped at 30fps. those above areas EXCEPT the purple areas have now been figured out(for the most part).

 

As far as that purple area goes, theres no way on earth I'm redesigning those doubly arched trim patches as brushes for that relatively small amount of polys. if anything i'll just reduce the patch tessalation by 1 or 2 and that will work fine, although reducing by 2 i think will result in a triangle looking trim sticking out of the wall on the Z axis, yuck.

Edited by ungoliant
Link to comment
Share on other sites

did you read my last post all the way through?

 

 

 

all the areas except purple including the fence area, including the lights, i deleted and then ran. it capped at 30fps. those above areas EXCEPT the purple areas have now been figured out(for the most part).

 

As far as that purple area goes, theres no way on earth I'm redesigning those doubly arched trim patches as brushes for that relatively small amount of polys. if anything i'll just reduce the patch tessalation by 1 or 2 and that will work fine, although reducing by 2 i think will result in a triangle looking trim sticking out of the wall on the Z axis, yuck.

 

Then I hope you enjoy 30 fps :P You wont be able to have nice scenery.

Link to comment
Share on other sites

It's v-sync, not "strange". It's either 60, or 30, or something lower (the exact multiples depend on your monitor refresh rate, also on Doom 3's capped 60fps). So if you turn v-sync off, you'll definitely see something above 30 in those areas

shadowdark50.gif keep50.gif
Link to comment
Share on other sites

It's v-sync, not "strange". It's either 60, or 30, or something lower (the exact multiples depend on your monitor refresh rate, also on Doom 3's capped 60fps). So if you turn v-sync off, you'll definitely see something above 30 in those areas

 

now that is hella useful information, and matches up exactly with my experience testing this map. My small attic rooms and the main menu show up as 60fps, and other rooms show as 30, 25, 20, 19, 15, or 14 fps (not sure why on the 19 and 14, but they blink rapidly between 19-20 and 14-15). would suck to be at 30 fps and then achieve real performance improvement that does not show visible FPS improvements up until you get to 60 FPS.

 

now if i'm playing TDM, and have vsync enabled, and the map i'm playing runs currently at 30 fps but it could be at 48 fps without vsync...... why do i have vsync enabled?

Link to comment
Share on other sites

Yes, I always keep v-sync on. You'd theoretically be getting 48, but only like 2/3 of the screen would get it and the bottom third would be cut off on the last frame due to your screen refreshing at an in-opportune moment. v-sync simply makes sure you never get that tearing, and even though it seems to "limit" your frame-rate, really it just keeps things proper looking.

 

But for testing purposes, you'd definitely want it off so you can see exact performances like you want to test above.

shadowdark50.gif keep50.gif
Link to comment
Share on other sites

with the aforementioned articles deleted and v-synch disabled, the map runs at 35-45 fps. strangely enough, as long as i keep the view mostly off the ground, which is one big ol' flat brush, it will average 45-50 fps even if looking straight at the entirety of the mansion. can't claim to understand that at all.

 

anyways, them be good numbers, so i think i got some texture designing and patch tessellation reduction to do. i'll bite the bullet on the 5 fps floodlight reduction, cuz it pretty much looks awesome.

Link to comment
Share on other sites

with the aforementioned articles deleted and v-synch disabled, the map runs at 35-45 fps. strangely enough, as long as i keep the view mostly off the ground, which is one big ol' flat brush, it will average 45-50 fps even if looking straight at the entirety of the mansion. can't claim to understand that at all.

 

If your ground is not cut into triangles (because only brushes touching it will cut it, if func_statics touch it, the won't split it), then you have some very large triangles around. And every light that hits one triangle causes one renderpath. So if you have a large ground tris and a lot of lights all hit it, the GPU renderes the same triangle multiple times, even tho maybe the lights never overlap on the ground.

 

r_showLightCount is your friend. You don't need to bring the light count down to 1, 3 or 5 is perfectly fine, but if every triangle on your screen is hit by 10 lights, it will slow down to a crawl (unless you have a monster GPU, then it will only be moderately slow due to CPU bottleneck issuing all the draw call).

 

anyways, them be good numbers, so i think i got some texture designing and patch tessellation reduction to do. i'll bite the bullet on the 5 fps floodlight reduction, cuz it pretty much looks awesome.

 

Yeah, I'd keep them, too.

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

 

"Remember: If the game lets you do it, it's not cheating." -- Xarax

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 5 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
    • The Black Arrow

      I wanna play Doom 3, but fhDoom has much better features than dhewm3, yet fhDoom is old, outdated and probably not supported. Damn!
      Makes me think that TDM engine for Doom 3 itself would actually be perfect.
      · 6 replies
    • Petike the Taffer

      Maybe a bit of advice ? In the FM series I'm preparing, the two main characters have the given names Toby and Agnes (it's the protagonist and deuteragonist, respectively), I've been toying with the idea of giving them family names as well, since many of the FM series have named protagonists who have surnames. Toby's from a family who were usually farriers, though he eventually wound up working as a cobbler (this serves as a daylight "front" for his night time thieving). Would it make sense if the man's popularly accepted family name was Farrier ? It's an existing, though less common English surname, and it directly refers to the profession practiced by his relatives. Your suggestions ?
      · 9 replies
    • nbohr1more

      Looks like the "Reverse April Fools" releases were too well hidden. Darkfate still hasn't acknowledge all the new releases. Did you play any of the new April Fools missions?
      · 5 replies
×
×
  • Create New...