Rendering/optimisation

Discussion in 'Mapping Questions & Discussion' started by DeOntwerper, Jan 8, 2015.

  1. DeOntwerper

    DeOntwerper L1: Registered

    Messages:
    46
    Positive Ratings:
    1
    Heya there,

    I have the following situation...

    [​IMG]

    Basically...The stuff you see (the locker/torches etc) shouldn't be rendered as I am on the floor above and cannot see them.

    How would I be able to make them render if I'm on the stairs, but if I'm above them make them not render?

    This is the first time I am learning full optimisation.
     
  2. yoghurt

    yoghurt L1: Registered

    Messages:
    47
    Positive Ratings:
    39
  3. DeOntwerper

    DeOntwerper L1: Registered

    Messages:
    46
    Positive Ratings:
    1
    That's the tutorial I read, however I am having issues with the hint/clip brushes not making stuff render properly.
     
  4. yoghurt

    yoghurt L1: Registered

    Messages:
    47
    Positive Ratings:
    39
    Did you try loading the portal file for your map to look at how the visleafs are looking?

    Or did you maybe compile with Vvis on fast?
     
  5. Ynders

    aa Ynders absolutely gormful

    Messages:
    403
    Positive Ratings:
    519
    You could try putting a func_occluder inside the wall between the stairs and the room you don't want rendered(make sure it has the occluder texture).
     
  6. wareya

    wareya L7: Fancy Member

    Messages:
    493
    Positive Ratings:
    172
    Obviously, did you compile with full vis? Do you have no leaks? Is your floor not func_detailed?

    I just realized that you're standing sort of in the same plane as the stair side of the ground. If you want that stuff to not render when you're in that position, you need to put an areaportal across the stair's hole in the floor. Make sure to not cause any areaportal leaks!
     
  7. xzzy

    aa xzzy

    Messages:
    815
    Positive Ratings:
    393
    Don't optimize before you need to because you'll never convince Source to draw exactly what you want all the time and you'll drive yourself crazy trying to make it do the right thing. Vis culling is an algorithm geared more towards image quality than performance, so Source is alway going to be rendering extra junk.

    A more sensible approach is to adhere to general map layout rules (divided fighting areas, S shaped halls, standard stuff) and deal with issues when they show up.

    You don't need perfect fps, you just need it good enough that people don't suffer hitches when fighting.
     
    • Thanks Thanks x 2
  8. UKCS-Alias

    aa UKCS-Alias Mann vs Machine... or... Mapper vs Meta?

    Messages:
    1,264
    Positive Ratings:
    748
    To be honest i think its an acceptable thing in this case and not realy worth optimizing yet. The amount of props is far too low to harm in this state. And since you are still able to partialy look into that room dont bother. I would just wait for later to see if it gets worse with the amount being rendered.

    If you want to be most effective areaportals might come in handy. They might take alot of effort, but are very effective at what becomes rendered. Specificly at windows and doorways they often are used as there they are most effective.

    However, a few hint brushes might help aswel and could prevent the need for areaportals. I would make a vertical one next to the stair. Once you move a little forward it would stop rendering the area below except for the staircase. the 2nd one would be at the door to prevent the right side props from being rendered, maybe another one at the window itself since they might be visible through that aswel.

    Also, is that wireframe set to 1, or set to 3? as 3 is more recommended due to it giving less lines. and might show the geometry better.
     
  9. Muddy

    Server Staff Muddy Muddy

    Messages:
    2,381
    Positive Ratings:
    4,206
    Honestly, you don't really need to worry about optimisation until your map is in beta stage. It's unlikely that an alpha map will be all that taxing on performance even on low-end computers.
     
  10. Crash

    aa Crash func_nerd

    Messages:
    3,148
    Positive Ratings:
    4,746
    That said, it doesn't hurt at all to plan your optimization out ahead of time. Keeping it in mind in the early stages helps save you from headaches in future versions.
     
    • Thanks Thanks x 2
  11. wareya

    wareya L7: Fancy Member

    Messages:
    493
    Positive Ratings:
    172
    A good rule of thumb is "don't build shit that is basicallyunoptimizable".
     
  12. DeOntwerper

    DeOntwerper L1: Registered

    Messages:
    46
    Positive Ratings:
    1
    There are more prop statics and prop dynamics in the area below now. It is mat_wireframe 2. The floor/stairs/walls are all prop details.

    The reason I asked as I wanted to get the optimisation correct for the future stuff I put in. Such as parts of the map are excluded from one another as well as open arears/buildings.
     
  13. Pocket

    aa Pocket func_croc

    Messages:
    4,489
    Positive Ratings:
    2,217
    I'm guessing there's a staircase connecting the floor you're on to the one under it? That would be the reason you're seeing it; the hole the stairs go through is making Source assume you can see into it no matter where you are. Maybe stretch a func_areaportal across that hole if it bothers you.

    EDIT: Oh, wait, yes of course you do; it's literally right next to you in that screenshot.
     
    Last edited: Jan 10, 2015
  14. henke37

    aa henke37

    Messages:
    1,876
    Positive Ratings:
    440
    I think the issue is that "prop_detail". That's not a what he actually meant. He meant that everything is func_detail. Which is wrong. Walls, floors and ceilings should be normal brushes so that they do cut up PVS-
     
  15. xzzy

    aa xzzy

    Messages:
    815
    Positive Ratings:
    393
    A better option might be to read around the internet about how vis in Source works, and how to block out a map in a way that allows vis to be the most effective. Spend a week building test maps with various techniques and study how it effects various parts of the map getting rendered.

    The problem is that vis is not intuitive at all and very hard to explain in a way that makes sense. Learning through experimentation can teach you a whole lot more, a whole lot quicker.

    Eventually you'll "get it" and will be able to return to your map with a bunch of awesome ideas to make everything super efficient.

    (and then get frustrated creatively because getting "perfect vis" seriously restricts design. which is why "good enough vis" is a much more reasonable goal)
     
    • Thanks Thanks x 1
  16. iiboharz

    aa iiboharz Meme Queen

    Messages:
    707
    Positive Ratings:
    1,030
    I think "good enough vis" would be like, not dropping below 60fps on a low-end rig.

    When you have people who typically run TF2 at like 200-300fps having their fps dropping to below 60fps you know you have vis problems.
     
    • Thanks Thanks x 1
  17. xzzy

    aa xzzy

    Messages:
    815
    Positive Ratings:
    393
    FPS targets aren't super useful because everyone's computer is going to be a little bit different. A "low end rig" in 2014 is massively different than a "low end rig" from 2010 or whatever.

    I will look for obvious problems by setting fps_max to -1 and observing a game with the max number of bots. Run around while they fight, look for big drops.

    Other than that my MO is to ignore optimization until someone complains in a playtest.

    (note that optimization is different than sensible layout, never ignore sensible layout)
     
  18. henke37

    aa henke37

    Messages:
    1,876
    Positive Ratings:
    440
    The two have some correlation, sightliness tend to lead to worse optimization while choke points and separate routes tend to lead to better optimization.