OpenTomb icon indicating copy to clipboard operation
OpenTomb copied to clipboard

Early frustum clipping

Open vvs- opened this issue 9 years ago • 15 comments

It seems that clipping happens too early. See for example setgamef(4,6) setEntityPos(player,27242,29836,0,16,0,0), then try to rotate camera to the left. Also, try to jump straight up.

vvs- avatar Jun 08 '15 23:06 vvs-

Could it be related to #40?

vvs- avatar Jun 23 '15 03:06 vvs-

I have a feeling that frustum angle is determined by the Lara position and not the camera.

vvs- avatar Jun 25 '15 19:06 vvs-

Another example, but this time in TR1: screen_00000 That yellow room above Lara should not be visible.

vvs- avatar Jul 09 '16 10:07 vvs-

I guess it belongs here: screen_00000

vvs- avatar Jul 16 '16 19:07 vvs-

In Obelisk of Khamoon: screen_00000 Happens after pulling switch 45.

vvs- avatar Jul 30 '16 19:07 vvs-

I can't seem to reproduce this, is this still happening on the current builds?

Gh0stBlade avatar Nov 27 '16 20:11 Gh0stBlade

I can still reproduce everything except one.

EDIT: As it turned out the last example can be reproduced on a debug optimization level.

vvs- avatar Nov 27 '16 21:11 vvs-

When running straight from that position I've got a total blackout. screen_00000

vvs- avatar Dec 06 '16 14:12 vvs-

The first case described above (and many others) manifests itself where only vertical frustums exists. Even when there should be line of vision above them (i.e. horizontal frustum), actually it doesn't exist from the engine point of view. When that vertical frustum is moved out of sight, everything above it suddenly disappear, e.g. top of buildings.

vvs- avatar Dec 07 '16 21:12 vvs-

And yet another case. Looks like it appeared only after recent changes: screen_00000

vvs- avatar Dec 07 '16 21:12 vvs-

Visibility problems are countless. Most times it's a wrong room in frustum. But sometimes there is nothing rendered at all: just Lara in the center of a black screen. screen_00000

vvs- avatar Dec 11 '16 13:12 vvs-

Another example of wrong culling of a room at the top by just moving slightly. screen_00000 screen_00001

vvs- avatar Dec 21 '16 17:12 vvs-

Visibility issues in TR2 are quite bad. There are instances when camera lose its room and you see a black screen. The only way to correct this is to use freelook/noclip.

vvs- avatar Jan 12 '17 16:01 vvs-

After recent camera and overlapping rooms fixes there are still many old visibility problems present: screen_00000

vvs- avatar Sep 07 '17 17:09 vvs-

screen_00000

vvs- avatar Sep 10 '17 20:09 vvs-