mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-26 06:16:24 -04:00
Merge pull request #438 from TwilitRealm/frame-interp-simplify
Frame interp simplify
This commit is contained in:
+9
-3
@@ -11018,6 +11018,15 @@ static int camera_execute(camera_process_class* i_this) {
|
||||
i_this->mCamera.CalcTrimSize();
|
||||
|
||||
store(i_this);
|
||||
|
||||
#ifdef TARGET_PC
|
||||
// record new camera for our sim frame
|
||||
dusk::frame_interp::record_camera(i_this, get_camera_id(i_this));
|
||||
// interpolate the view now so that this sim frame's view matrix matches what
|
||||
// we'll be rendering with later
|
||||
dusk::frame_interp::interp_view(&i_this->view);
|
||||
#endif
|
||||
|
||||
view_setup(i_this);
|
||||
return 1;
|
||||
}
|
||||
@@ -11086,9 +11095,6 @@ static int camera_draw(camera_process_class* i_this) {
|
||||
C_MTXPerspective(process->view.projMtx, process->view.fovy, process->view.aspect, process->view.near_, process->view.far_);
|
||||
mDoMtx_lookAt(process->view.viewMtx, &process->view.lookat.eye, &process->view.lookat.center,
|
||||
&process->view.lookat.up, process->view.bank);
|
||||
#ifdef TARGET_PC
|
||||
dusk::frame_interp::record_camera(process, camera_id);
|
||||
#endif
|
||||
|
||||
#if WIDESCREEN_SUPPORT
|
||||
mDoGph_gInf_c::setWideZoomProjection(process->view.projMtx);
|
||||
|
||||
Reference in New Issue
Block a user