Implement unlocked framerates via interpolation (#315)

* Disable waitForTick and waitBlanking

* Initial frame interpolation implementation

* Initial batch of speed fixes

* Fix Iron Boots

* Strip dead code once used for debugging

* Interpolate shadows

* Revert overzealous/redundant lookups

* Fix JUTFader

* Fix field map cursor

* Fix various particle effects

* Fix Midna when riding Wolf Link

* Fix title logo

* Title Logo 2: Electric Boogaloo

* Fixed grass and flowers

* "Unlock Framerate" config option (WIP)

* Wrap more things in TARGET_PC

* Finish wrapping things in TARGET_PC

* Missed one

* Disable dComIfGd_drawXluListInvisible when interpolating

---------

Co-authored-by: Luke Street <luke@street.dev>
This commit is contained in:
Irastris
2026-04-11 03:06:25 -04:00
committed by GitHub
parent 8c07d8bb8e
commit fb9178cac9
33 changed files with 1039 additions and 147 deletions
+7
View File
@@ -14,6 +14,7 @@
#include "d/d_msg_object.h"
#include "d/d_s_play.h"
#include "d/d_debug_viewer.h"
#include "dusk/frame_interpolation.h"
static f32 dummy_lit_3777(int idx, u8 foo) {
Vec dummy_vec = {0.0f, 0.0f, 0.0f};
@@ -1052,6 +1053,12 @@ void daMidna_c::setBodyPartMatrix() {
mpModel->setAnmMtx(i, mpShadowModel->getAnmMtx(i));
}
mpModel->calcWeightEnvelopeMtx();
#ifdef TARGET_PC
// Frame interpolation: Record weight envelopes for Midna here, as they are otherwise missed causing distortion
for (u16 i = 0; i < mpModel->getModelData()->getWEvlpMtxNum(); i++) {
dusk::frame_interp::record_final_mtx_raw(reinterpret_cast<const Mtx*>(mpModel->getWeightAnmMtx(i)), mpModel->getWeightAnmMtx(i));
}
#endif
}
mDoMtx_stack_c::transS(mpShadowModel->getAnmMtx(JNT_BACKBONE1)[0][3],