http://www.angelmapper.com/gamedev/tutorials/optimization1.htm
This tutorial explains things fairly well for me. One thing that doesn't match up, the tutorial says zones will occlude static meshes in other zones automatically if you can't see any part of the mesh. It says you should be able to see the effect in the viewport. My viewport shows every mesh, every bsp, everything in the map all the time. I have 3 zones, I've checked different angles and everything is always there. Any ideas? Maybe I don't need any anti-portals at all? Maybe I just need to set some sort of zone auto-occlude setting somewhere? Anyone with knowledge would be appreciated.
More background info from another thread:
I am pretty sure I do need them as my map is pretty big and is lagging in certain area's especially as I add more detail. I'm not entirely sure what the best approach is going to be for adding them since, as you say, they need to be used sparingly. You should be able to see pictures of my map on my screenshoots page, if you can get to it. Anyway, I'll describe it quickly. The map contains one large building that takes up an entire city block, all the other buildings or city blocks are filled with BSP surfaces for the buildings and these area's are blocked off to the player... just stuff to make it look like a real city in the background. The one building that takes up an entire city block is the main playing area, you can play in front of the building in the street or inside the building in a plethoria of rooms, one of which is a huge concert hall, and the roof.
I am pretty sure you've seen the map I'm working on for the past year, you may even have a copy of an older version.... didn't you fix that red tint on my meshes problem for me?
Anyway, I am 90% sure I want to cull everything inside the building when the player is outside the building; also, I would want to cull everything outside the building when the player is inside the building... does this require two antiportals? One of the inside wall and one for the outside? Should I use a Zone antiportal for this?
Also the big concert hall room should always be culled when the player isn't in it... it could be a map in itself... also, the rest of the map should be culled when the player is in the main concert hall.
Basically what I am proposing is to put a antiportal box around the entire building and within that building, puting antiportal sheets within the BSP to cull the concert hall. But again, the culling needs to apply in both directions... when your in the room, cull the map, when your not in the room, cull the room. I haven't found this functionality discussed anywhere, so seems like something special needs to happen.
Note also that the main building has tons of windows and the building is zoned off from everything else. I would like to maintain visibility through the windows from the outside, so the anitportal needs to replicate the windows. I though using the BSP service would be the best thing, but I've read that it will ignore the windows and doors. Basically the outside of the building walls is all BSP with a static mesh stuck on top of it. Same type of issue with the doors in the concert hall.
I have also read that anitportals can negate each other so that this proposal wouldn't work. Like, with this proposal, if a player is outside and looks at the building, everything in the building (not seen through windows) would be culled, except for the main concert hall which has it's own antiportals that are behind the buildings antiportals. How do I deal with this?
This tutorial explains things fairly well for me. One thing that doesn't match up, the tutorial says zones will occlude static meshes in other zones automatically if you can't see any part of the mesh. It says you should be able to see the effect in the viewport. My viewport shows every mesh, every bsp, everything in the map all the time. I have 3 zones, I've checked different angles and everything is always there. Any ideas? Maybe I don't need any anti-portals at all? Maybe I just need to set some sort of zone auto-occlude setting somewhere? Anyone with knowledge would be appreciated.
More background info from another thread:
I am pretty sure I do need them as my map is pretty big and is lagging in certain area's especially as I add more detail. I'm not entirely sure what the best approach is going to be for adding them since, as you say, they need to be used sparingly. You should be able to see pictures of my map on my screenshoots page, if you can get to it. Anyway, I'll describe it quickly. The map contains one large building that takes up an entire city block, all the other buildings or city blocks are filled with BSP surfaces for the buildings and these area's are blocked off to the player... just stuff to make it look like a real city in the background. The one building that takes up an entire city block is the main playing area, you can play in front of the building in the street or inside the building in a plethoria of rooms, one of which is a huge concert hall, and the roof.
I am pretty sure you've seen the map I'm working on for the past year, you may even have a copy of an older version.... didn't you fix that red tint on my meshes problem for me?
Anyway, I am 90% sure I want to cull everything inside the building when the player is outside the building; also, I would want to cull everything outside the building when the player is inside the building... does this require two antiportals? One of the inside wall and one for the outside? Should I use a Zone antiportal for this?
Also the big concert hall room should always be culled when the player isn't in it... it could be a map in itself... also, the rest of the map should be culled when the player is in the main concert hall.
Basically what I am proposing is to put a antiportal box around the entire building and within that building, puting antiportal sheets within the BSP to cull the concert hall. But again, the culling needs to apply in both directions... when your in the room, cull the map, when your not in the room, cull the room. I haven't found this functionality discussed anywhere, so seems like something special needs to happen.
Note also that the main building has tons of windows and the building is zoned off from everything else. I would like to maintain visibility through the windows from the outside, so the anitportal needs to replicate the windows. I though using the BSP service would be the best thing, but I've read that it will ignore the windows and doors. Basically the outside of the building walls is all BSP with a static mesh stuck on top of it. Same type of issue with the doors in the concert hall.
I have also read that anitportals can negate each other so that this proposal wouldn't work. Like, with this proposal, if a player is outside and looks at the building, everything in the building (not seen through windows) would be culled, except for the main concert hall which has it's own antiportals that are behind the buildings antiportals. How do I deal with this?
Last edited: