mirror of
https://github.com/Zelda64Recomp/Zelda64Recomp
synced 2025-10-06 00:22:39 +02:00
Update runtime for more accurate VI and switch to improved pacing RT64 branch (#644)
* Update runtime for more accurate VI and switch to improved pacing RT64 branch * Update N64ModernRuntime and RT64 after merge * Update recompiler to match runtime symbol list
This commit is contained in:
2
.github/workflows/validate.yml
vendored
2
.github/workflows/validate.yml
vendored
@@ -9,7 +9,7 @@ on:
|
||||
N64RECOMP_COMMIT:
|
||||
type: string
|
||||
required: false
|
||||
default: '989a86b36912403cd323de884bf834f2605ea770'
|
||||
default: 'a13e5cff96686776b0e03baf23923e3c1927b770'
|
||||
DXC_CHECKSUM:
|
||||
type: string
|
||||
required: false
|
||||
|
@@ -291,7 +291,7 @@ if (WIN32)
|
||||
)
|
||||
|
||||
target_sources(Zelda64Recompiled PRIVATE ${CMAKE_SOURCE_DIR}/icons/app.rc)
|
||||
target_link_libraries(Zelda64Recompiled PRIVATE SDL2)
|
||||
target_link_libraries(Zelda64Recompiled PRIVATE SDL2 Winmm.lib)
|
||||
endif()
|
||||
|
||||
if (APPLE)
|
||||
|
@@ -27,7 +27,7 @@ namespace zelda64 {
|
||||
|
||||
void enable_instant_present() override;
|
||||
void send_dl(const OSTask *task) override;
|
||||
void update_screen(uint32_t vi_origin) override;
|
||||
void update_screen() override;
|
||||
void shutdown() override;
|
||||
uint32_t get_display_framerate() const override;
|
||||
float get_resolution_scale() const override;
|
||||
|
@@ -7,7 +7,8 @@
|
||||
"project": "CMakeLists.txt",
|
||||
"projectTarget": "Zelda64Recompiled.exe",
|
||||
"name": "Zelda64Recompiled.exe",
|
||||
"currentDir": "${workspaceRoot}"
|
||||
"currentDir": "${workspaceRoot}",
|
||||
"args": ["--show-console"]
|
||||
}
|
||||
]
|
||||
}
|
Submodule lib/N64ModernRuntime updated: cea072b59b...df7e820d8c
2
lib/rt64
2
lib/rt64
Submodule lib/rt64 updated: 5164996361...b552151c34
@@ -50,6 +50,7 @@
|
||||
#ifdef _WIN32
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <Windows.h>
|
||||
#include <timeapi.h>
|
||||
#include "SDL_syswm.h"
|
||||
#endif
|
||||
|
||||
@@ -586,6 +587,10 @@ int main(int argc, char** argv) {
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
// Set up high resolution timing period.
|
||||
timeBeginPeriod(1);
|
||||
|
||||
// Process arguments.
|
||||
for (int i = 1; i < argc; i++)
|
||||
{
|
||||
if (strcmp(argv[i], "--show-console") == 0)
|
||||
@@ -745,5 +750,10 @@ int main(int argc, char** argv) {
|
||||
release_preload(preload_context);
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
// End high resolution timing period.
|
||||
timeEndPeriod(1);
|
||||
#endif
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
|
@@ -56,21 +56,6 @@ unsigned int DPC_BUFBUSY_REG = 0;
|
||||
unsigned int DPC_PIPEBUSY_REG = 0;
|
||||
unsigned int DPC_TMEM_REG = 0;
|
||||
|
||||
unsigned int VI_STATUS_REG = 0;
|
||||
unsigned int VI_ORIGIN_REG = 0;
|
||||
unsigned int VI_WIDTH_REG = 0;
|
||||
unsigned int VI_INTR_REG = 0;
|
||||
unsigned int VI_V_CURRENT_LINE_REG = 0;
|
||||
unsigned int VI_TIMING_REG = 0;
|
||||
unsigned int VI_V_SYNC_REG = 0;
|
||||
unsigned int VI_H_SYNC_REG = 0;
|
||||
unsigned int VI_LEAP_REG = 0;
|
||||
unsigned int VI_H_START_REG = 0;
|
||||
unsigned int VI_V_START_REG = 0;
|
||||
unsigned int VI_V_BURST_REG = 0;
|
||||
unsigned int VI_X_SCALE_REG = 0;
|
||||
unsigned int VI_Y_SCALE_REG = 0;
|
||||
|
||||
void dummy_check_interrupts() {}
|
||||
|
||||
RT64::UserConfiguration::Antialiasing compute_max_supported_aa(RT64::RenderSampleCounts bits) {
|
||||
@@ -250,20 +235,22 @@ zelda64::renderer::RT64Context::RT64Context(uint8_t* rdram, ultramodern::rendere
|
||||
appCore.DPC_PIPEBUSY_REG = &DPC_PIPEBUSY_REG;
|
||||
appCore.DPC_TMEM_REG = &DPC_TMEM_REG;
|
||||
|
||||
appCore.VI_STATUS_REG = &VI_STATUS_REG;
|
||||
appCore.VI_ORIGIN_REG = &VI_ORIGIN_REG;
|
||||
appCore.VI_WIDTH_REG = &VI_WIDTH_REG;
|
||||
appCore.VI_INTR_REG = &VI_INTR_REG;
|
||||
appCore.VI_V_CURRENT_LINE_REG = &VI_V_CURRENT_LINE_REG;
|
||||
appCore.VI_TIMING_REG = &VI_TIMING_REG;
|
||||
appCore.VI_V_SYNC_REG = &VI_V_SYNC_REG;
|
||||
appCore.VI_H_SYNC_REG = &VI_H_SYNC_REG;
|
||||
appCore.VI_LEAP_REG = &VI_LEAP_REG;
|
||||
appCore.VI_H_START_REG = &VI_H_START_REG;
|
||||
appCore.VI_V_START_REG = &VI_V_START_REG;
|
||||
appCore.VI_V_BURST_REG = &VI_V_BURST_REG;
|
||||
appCore.VI_X_SCALE_REG = &VI_X_SCALE_REG;
|
||||
appCore.VI_Y_SCALE_REG = &VI_Y_SCALE_REG;
|
||||
ultramodern::renderer::ViRegs* vi_regs = ultramodern::renderer::get_vi_regs();
|
||||
|
||||
appCore.VI_STATUS_REG = &vi_regs->VI_STATUS_REG;
|
||||
appCore.VI_ORIGIN_REG = &vi_regs->VI_ORIGIN_REG;
|
||||
appCore.VI_WIDTH_REG = &vi_regs->VI_WIDTH_REG;
|
||||
appCore.VI_INTR_REG = &vi_regs->VI_INTR_REG;
|
||||
appCore.VI_V_CURRENT_LINE_REG = &vi_regs->VI_V_CURRENT_LINE_REG;
|
||||
appCore.VI_TIMING_REG = &vi_regs->VI_TIMING_REG;
|
||||
appCore.VI_V_SYNC_REG = &vi_regs->VI_V_SYNC_REG;
|
||||
appCore.VI_H_SYNC_REG = &vi_regs->VI_H_SYNC_REG;
|
||||
appCore.VI_LEAP_REG = &vi_regs->VI_LEAP_REG;
|
||||
appCore.VI_H_START_REG = &vi_regs->VI_H_START_REG;
|
||||
appCore.VI_V_START_REG = &vi_regs->VI_V_START_REG;
|
||||
appCore.VI_V_BURST_REG = &vi_regs->VI_V_BURST_REG;
|
||||
appCore.VI_X_SCALE_REG = &vi_regs->VI_X_SCALE_REG;
|
||||
appCore.VI_Y_SCALE_REG = &vi_regs->VI_Y_SCALE_REG;
|
||||
|
||||
// Set up the RT64 application configuration fields.
|
||||
RT64::ApplicationConfiguration appConfig;
|
||||
@@ -338,9 +325,7 @@ void zelda64::renderer::RT64Context::send_dl(const OSTask* task) {
|
||||
app->processDisplayLists(app->core.RDRAM, task->t.data_ptr & 0x3FFFFFF, 0, true);
|
||||
}
|
||||
|
||||
void zelda64::renderer::RT64Context::update_screen(uint32_t vi_origin) {
|
||||
VI_ORIGIN_REG = vi_origin;
|
||||
|
||||
void zelda64::renderer::RT64Context::update_screen() {
|
||||
app->updateScreen();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user