mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-09-06 09:55:11 -04:00
Frame interp: Revised camera system
FOV is now smooth, and the individual hacks for stars and Epona's reins are removed
This commit is contained in:
@@ -2229,13 +2229,11 @@ int mDoGph_Painter() {
|
||||
|
||||
#if TARGET_PC
|
||||
if (dusk::getSettings().game.enableFrameInterpolation) {
|
||||
cXyz pres_eye;
|
||||
dusk::frame_interp::camera_eye_from_view_mtx(j3dSys.getViewMtx(), &pres_eye);
|
||||
// FRAME INTERP NOTE: Currently only recalculating points for Epona's reins. Need a more global solution.
|
||||
if (daHorse_c* horse = dComIfGp_getHorseActor()) {
|
||||
horse->lerpControlPoints(dusk::frame_interp::get_interpolation_step());
|
||||
}
|
||||
g_dComIfG_gameInfo.drawlist.refresh3DlineMats(pres_eye);
|
||||
g_dComIfG_gameInfo.drawlist.refresh3DlineMats(camera_p->view.lookat.eye);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -253,7 +253,10 @@ void main01(void) {
|
||||
accumulator -= kSimStepSeconds;
|
||||
}
|
||||
dusk::frame_interp::interpolate(static_cast<float>(accumulator / kSimStepSeconds));
|
||||
cAPIGph_Painter();
|
||||
{
|
||||
dusk::frame_interp::PresentationCameraScope presentation_camera;
|
||||
cAPIGph_Painter();
|
||||
}
|
||||
} else {
|
||||
accumulator = 0.0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user