Advertisement

Portal Culling, and the Borders Between Cells

Started by June 02, 2017 06:46 PM
-1 comments, last by Thaumaturge 7 years, 8 months ago

I'm using portal culling in my current project, and while it seems to work well overall, I find myself uncertain of how to proceed on one particular point: how to handle objects--especially dynamic objects--placed over the boundaries between cells.

As I have things at the moment, there are gaps between the cells used for portal-culling. I honestly forget why this is; I just recall that I had some reason for doing so. (It may be related to the fact that--if I have it correct--this portal-culling system allows only a single parent-cell for each object.)

As to my portals, I place these slightly within their destination cells; I think that this was so that the camera's near-plane didn't pass a portal--thus removing the objects to which it allows view--before the camera entered the destination cell of that portal.

Static objects, included in the level-geometry, aren't that difficult to deal with: they can be split at the border, and such elements are manually attached to their parent cells in any case.

Dynamic objects, whether unmoving-but-animated, such as doors, or simply objects that move or that may be placed down by the player, are more troublesome.

It might be feasible for me to move my cell-boundaries such that they overlap--as I said, I don't recall why I decided to space them apart, and said reason, whatever it is, might prove surmountable or obviated. Even so, that leaves a gap between portals, allowing for the possibility of an object being "behind" the portal that should reveal it.

Does anyone have any suggestions regarding this? (Would it be a good idea to move the point from which I determine the camera's current cell to sit at the centre of the near-plane, rather than at the camera's origin?) I imagine that portal culling is fairly well-understood by now, so how are such cases usually handled?

MWAHAHAHAHAHAHA!!!

My Twitter Account: @EbornIan

This topic is closed to new replies.

Advertisement