Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tr2: 60fps (temporary PR) #2550

Draft
wants to merge 11 commits into
base: develop
Choose a base branch
from
Draft

Conversation

lahm86
Copy link
Collaborator

@lahm86 lahm86 commented Feb 24, 2025

Checklist

  • I have read the coding conventions
  • I have added a changelog entry about what my pull request accomplishes, or it is an internal change
  • I have added a readme entry about my new feature or OG bug fix, or it is a different change

Description

This builds on #2544, and is separated to make test builds available (shared branch writing issues otherwise, this is for ease). Please continue to add issues/comments to #2544 rather than here. Thanks!

@lahm86 lahm86 requested review from a team as code owners February 24, 2025 20:56
@lahm86 lahm86 requested review from rr- and walkawayy and removed request for a team February 24, 2025 20:56
@lahm86 lahm86 marked this pull request as draft February 24, 2025 20:56
@lahm86 lahm86 removed request for a team, rr- and walkawayy February 24, 2025 20:57
@lahm86 lahm86 mentioned this pull request Feb 24, 2025
10 tasks
Copy link

github-actions bot commented Feb 24, 2025

@lahm86 lahm86 force-pushed the fps60-cont branch 17 times, most recently from 034d0bd to 37c3611 Compare March 3, 2025 21:37
rr- and others added 9 commits March 8, 2025 21:33
This covers not interpolating items that are inactive, such as stopped
boulders. An item may still be active in the item list such that it
retains collision, but inanimate, sich as boulders or mines, so we need
to check both statuses. The TR1 test here has also been simplified to
match.

TR2 mines have a bad frame in the level data, so we avoid interpolating
these in all cases. The push button also has a single frame where a
mesh is rotated 180deg to simulate off/on, so this can't be
interpolated.
This moves Object_DrawInterpolatedObject from TR1 to TRX, and updates
TR2's Object_DrawAnimatingItem to use this as the logic is identical.
This updates TR2's inventory to use Object_DrawInterpolatedObject so
interpolation is taken into account. Custom behaviour for the stopwatch
retained.
This updates camera interpolation in cases where there are large shifts
of any positional value, such as going to a fixed camera on the other
side of the world. In this case, we just commit the values rather than
interpolating each one, as this can result in the camera having settle
at the destination.
I think prior to this, the shade value happened to be less than zero so
it was having dynamic lighting applied, but the value should be
enforced on creation.
This resolves various TR1 and TR2 effects jittering in 60fps, and
ensures grenades and harpoons (from Lara) are interpolated.
This fixes some frames in TR2 cutscenes where the camera perspective
changes, but not quite enough to hit on any coordinate to reach the 512
threshold.
This performs bounds tests on the interpolated camera result to avoid
instances where black screens can occur.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In review
Development

Successfully merging this pull request may close these issues.

2 participants