mirror of
https://github.com/Zelda64Recomp/Zelda64Recomp
synced 2026-07-09 23:02:03 -04:00
1.2.1 Changes (#625)
* Update runtime for hook and callback sorting, update version number * Actually update version number * Automatically open mods menu when dragging a mod which also prevents issues when installing a mod from the launcher menu * Update RT64 to add texture pack shift configuration and fix minimized memory leak * Update runtime for return hook getter exports * Actually update rt64 * Update RT64 to fix texture pack ordering * Implement optional dependencies, fix memory slotmaps, bump version number to 1.2.1-dev * Add command-line option to show console output on Windows. (#632) * Add new raphnet adapter revision to controller DB * Add another mayflash N64 adapter to the controller database file * Update runtime after merge for optional dependencies * Update runtime for optional dependency mod callback fix * Add mayflash magic NS to controller database * Update RT64 for extended address fix and x11 dependency removal * Update RT64 to fix build issue caused by x11 * Update runtime to remove unnnecessary x11 includes * Fix more x11 define compilation issues * Fix the x86-64 CPU requirement listing in the readme (#634) * Transform tagging for keaton grass tornado * Interpolation for sword trails * Switch RT64 to gEXVertex fix branch (temporary until merge) * Add 8bitdo 64 bluetooth controller to database * Add export to get bowstring transform ID * Update RT64 to fix linux dev mode menu and texture streaming race condition * Fix all the interpolation glitches in the Gibdo Mask cutscene (#641) * Fix the actor extension API breaking when registering an extension for actor type 0 first * Remove slotmap submodule and integrate header directly after submodule URL changed * Transform tagging for ObjGrass * Adding autosave events. (#611) * Adding autosave events. Dead simple. * Update autosaving.c to include @recomp_event comments * Prevent autosaves during minigames and fix holding powder keg on autosave load (#640) * 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 * Remove unused gibdo patch file --------- Co-authored-by: Darío <dariosamo@gmail.com> Co-authored-by: Reonu <15913880+Reonu@users.noreply.github.com>
This commit is contained in:
@@ -79,7 +79,7 @@ extern "C" void recomp_register_actor_extension(uint8_t* rdram, recomp_context*
|
||||
}
|
||||
|
||||
if (actor_data_sizes.size() <= actor_type) {
|
||||
actor_data_sizes.resize(2 * actor_type);
|
||||
actor_data_sizes.resize(actor_type + 1);
|
||||
}
|
||||
|
||||
// Increase the actor type's extension data size by the provided size (rounded up to a multiple of 16).
|
||||
|
||||
@@ -569,8 +569,18 @@ void recomputil_u32_slotmap_size(uint8_t* rdram, recomp_context* ctx) {
|
||||
// memory slotmap.
|
||||
|
||||
void recomputil_create_memory_slotmap(uint8_t* rdram, recomp_context* ctx) {
|
||||
(void)rdram;
|
||||
_return(ctx, memory_slotmaps.create());
|
||||
uint32_t element_size = _arg<0, uint32_t>(rdram, ctx);
|
||||
|
||||
// Create the map.
|
||||
uint32_t map_key = memory_slotmaps.create();
|
||||
|
||||
// Retrieve the map and set its element size to the provided value.
|
||||
MemorySlotmap* map;
|
||||
memory_slotmaps.get(map_key, &map);
|
||||
map->second = element_size;
|
||||
|
||||
// Return the created map's key.
|
||||
_return(ctx, map_key);
|
||||
}
|
||||
|
||||
void recomputil_destroy_memory_slotmap(uint8_t* rdram, recomp_context* ctx) {
|
||||
@@ -628,7 +638,7 @@ void recomputil_memory_slotmap_create(uint8_t* rdram, recomp_context* ctx) {
|
||||
// Store the allocated pointer.
|
||||
PTR(void)* value_ptr;
|
||||
map->first.get(key, &value_ptr);
|
||||
MEM_W(0, *value_ptr) = addr;
|
||||
*value_ptr = static_cast<PTR(void)>(addr);
|
||||
|
||||
// Return the key.
|
||||
_return(ctx, key);
|
||||
|
||||
+34
-1
@@ -18,6 +18,13 @@
|
||||
#else
|
||||
#include "SDL2/SDL.h"
|
||||
#include "SDL2/SDL_syswm.h"
|
||||
// Undefine x11 macros that get included by SDL_syswm.h.
|
||||
#undef None
|
||||
#undef Status
|
||||
#undef LockMask
|
||||
#undef ControlMask
|
||||
#undef Success
|
||||
#undef Always
|
||||
#endif
|
||||
|
||||
#include "recomp_ui.h"
|
||||
@@ -43,12 +50,13 @@
|
||||
#ifdef _WIN32
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <Windows.h>
|
||||
#include <timeapi.h>
|
||||
#include "SDL_syswm.h"
|
||||
#endif
|
||||
|
||||
#include "../../lib/rt64/src/contrib/stb/stb_image.h"
|
||||
|
||||
const std::string version_string = "1.2.0";
|
||||
const std::string version_string = "1.2.1-dev";
|
||||
|
||||
template<typename... Ts>
|
||||
void exit_error(const char* str, Ts ...args) {
|
||||
@@ -579,6 +587,26 @@ 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)
|
||||
{
|
||||
if (GetConsoleWindow() == nullptr)
|
||||
{
|
||||
AllocConsole();
|
||||
freopen("CONIN$", "r", stdin);
|
||||
freopen("CONOUT$", "w", stderr);
|
||||
freopen("CONOUT$", "w", stdout);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Set up console output to accept UTF-8 on windows
|
||||
SetConsoleOutputCP(CP_UTF8);
|
||||
|
||||
@@ -722,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();
|
||||
}
|
||||
|
||||
|
||||
@@ -900,6 +900,13 @@ void recompui::drop_files(const std::list<std::filesystem::path> &file_list) {
|
||||
return;
|
||||
}
|
||||
|
||||
recompui::set_config_tab(recompui::ConfigTab::Mods);
|
||||
// If the config menu isn't open, open it in the mods tab.
|
||||
if (!recompui::is_context_shown(recompui::get_config_context_id())) {
|
||||
recompui::hide_all_contexts();
|
||||
recompui::show_context(recompui::get_config_context_id(), "");
|
||||
}
|
||||
|
||||
recompui::open_notification("Installing Mods", "Please Wait");
|
||||
// TODO: Needs a progress callback and a prompt for every mod that needs to be confirmed to be overwritten.
|
||||
// TODO: Run this on a background thread and use the callbacks to advance the state instead of blocking.
|
||||
|
||||
Reference in New Issue
Block a user