I make 3D FPS with OpenGL, and here are the basic principles of its operation. The game is a 3D array of cubes. I know the location of the player’s current cube, as well as the camera x, y, z, and I know that x, y, z rotates the camera too. Right now, I'm just making a square around the player and doing it, and then adding distant fog. The problem, however, is that I'm still doing everything the player has behind. How can I selectively display only what the player sees, and not display everything in radius X, as I do now.
thank
source
share