BSP trees for geometry culling
Posted: 28 Mar 2023, 10:54
Hi, one thing that bugged the hell out of me about OpenMW was (years ago) that when I was facing a wall the fps was like 20fps in Seyda Neen and when facing the open town the fps was the same.
I expected the fps to go a lot higher when facing directly to a wall, exponentially. I don't know why I got so low fps, maybe it was the mods. It's not relevant. The point I'm doing here is that I believe that geometry is drawn behind the wall and then overdrawn by the wall.
This is bugging me. I thought about BSP trees, like Doom and Quake used to preprocess all the map and drawn things correctly without overdrawing. This is a preprocessing step before launching the game.
Would it be cool or wise to test a fork or a branch with BSP trees involved? What would I need in order to do that and test it by myself? I'm fluent in C++, SDL, Tilengine and SFML, and object-oriented programming, but have not touched or compiled the code of OpenMW.
This links are informative:
I expected the fps to go a lot higher when facing directly to a wall, exponentially. I don't know why I got so low fps, maybe it was the mods. It's not relevant. The point I'm doing here is that I believe that geometry is drawn behind the wall and then overdrawn by the wall.
This is bugging me. I thought about BSP trees, like Doom and Quake used to preprocess all the map and drawn things correctly without overdrawing. This is a preprocessing step before launching the game.
Would it be cool or wise to test a fork or a branch with BSP trees involved? What would I need in order to do that and test it by myself? I'm fluent in C++, SDL, Tilengine and SFML, and object-oriented programming, but have not touched or compiled the code of OpenMW.
This links are informative:
- BSP trees: https://www.youtube.com/watch?v=yTRzfKh4Tg0
- Occlusion culling in Quake 3: https://www.youtube.com/watch?v=s2yRYpPqL9k
- Doom BSP use: https://www.youtube.com/watch?v=hYMZsMMlubg
- BSP trees article explanation: https://www.geeksforgeeks.org/binary-sp ... titioning/