Commit Graph

6867 Commits

Author SHA1 Message Date
SimonAfek 50f02ae172
Fix broken macOS interface build (#679)
* Update macOS version in build_interface.yml
* Typo fixes in build_interface.yml
2023-07-12 08:49:01 +00:00
rogerman 0fc3306bfc Cocoa Port: Standardize all Internal cheat direct memory writes (clicking the 'Write Once' button) to write to NDS memory before NDS_exec() is called. 2023-07-08 20:28:01 -07:00
rogerman f240472f5e Cheat System: Standardize memory writes for all cheat types. Most notably, Internal cheats now reset the JIT in the same way as Action Replay cheats do. 2023-07-08 19:52:10 -07:00
rogerman 12347c7cd9 Cocoa Port: Continue refactoring the cheat system code, Part IV.
- Add the following C++ classes: ClientCheatSearcher, ClientCheatDatabase
- Remove the following Obj-C classes: CocoaDSCheatSearch, CocoaDSCheatSearchParams
- Remove duplicate GUI code from EmuControllerDelegate.mm and preferencesWindowDelegate.mm
- All basic functionality for managing game session cheat items, the cheat database list, and cheat search are now managed through CocoaDSCheatManager.
2023-07-07 19:31:26 -07:00
rogerman d00e6355da Cocoa Port: Continue refactoring the cheat system code.
- Add ClientCheatManager C++ class, further reducing dependence on Objective-C code.
2023-07-02 22:54:13 -07:00
rogerman 946f7df9bc Cocoa Port: Continue refactoring the cheat system code.
- Add new ClientCheatList C++ class, further reducing dependence on Objective-C code.
- Making any changes to the cheat list or to any cheat items no longer requires the acquisition of an R/W lock.
2023-06-30 20:04:19 -07:00
rogerman 4e7926eaa1 Windows Port: Fix compiling issue that prevented building. (Regression from commit 7fb5a58.) 2023-06-30 15:58:22 -07:00
rogerman 7fb5a5871b Cheat System: Minor code cleanup and robustness improvements. 2023-06-30 15:13:35 -07:00
zeromus f48aee928c fix bug from 9767f79346 that made the cheat search results list produce strange cheats without 0x02xxxxxx prefix that don't work 2023-06-25 18:24:53 -04:00
rogerman ba83b68b7f Cocoa Port: Begin work on cleaning up and refactoring the cheat system. Also add some quality-of-life improvements to the GUI while I'm at it.
- Add new ClientCheatItem C++ class to handle cheat items, greatly reducing dependence on Objective-C code.
- Remove a bunch of methods from CocoaDSCheatItem and CocoaDSCheatManager that were never used and are no longer planned to ever be used in the new code refactor.
- The Cheat Manager window may now be resized.
- The Action Replay code editor now uses Monaco 13 font instead of the system default font.
- The command for "Enable/Disable Cheats" has been renamed to "Enable/Disable Cheat System" to help clarify that the command affects the entire cheat system as a whole, as opposed to enabling/disabling individual cheat items.
2023-06-23 14:18:02 -07:00
rogerman aeefd86f57 Cocoa Port: In the cheat system code, remove Obj-C dot syntax for object properties to avoid ambiguity with features from other languages. 2023-06-21 14:53:49 -07:00
rogerman b468aee01a Linux GTK Port: Fix compiling issues that prevented building. (Regression from commit aa21454.) 2023-06-20 17:12:53 -07:00
rogerman aa21454373 Cheat System: Do some code cleanup and silence all of the compiler warnings (on Windows and Cocoa ports only).
- Some minor API changes were made, but only Windows and Cocoa were actually tested. Tried to make sure that Linux ports were updated to the new API, but haven't tested it.
2023-06-20 16:44:30 -07:00
rogerman cedc1c9f38 Cocoa Port: Add option for Catmull-Rom sound interpolation in the GUI. Also update tooltips for all interpolation methods to better reflect how they compare to one another. 2023-06-20 14:06:04 -07:00
rogerman 8bba9dc955 Cocoa Port: Due to commit fac70ce fixing FBO issues with older GPUs, OpenGL rendering is now returning to PowerPC Macs. This change effectively reverts commit 4708404. 2023-06-19 18:44:14 -07:00
rogerman 5c805b2de0 Cocoa Port: Fix some compiler warnings. 2023-06-14 13:57:30 -07:00
zeromus 7c2f281d25
Merge pull request #674 from oheikk/fix-audio-volume-resetting
Fix audio volume resetting on posix/gtk
2023-06-08 16:46:43 -04:00
Oskari Heikkinen 941c2e39be Fix audio volume resetting on posix/gtk 2023-06-08 22:47:26 +03:00
zeromus 1bde1c28ac fix non-windows compilation, maybe. could be bugged, didnt test 2023-05-28 14:31:50 -04:00
zeromus 3511e14ac6 winport: path settings support unicode now (fixes #669). old ini files may malfunction since they're now expected to be written with unicode. old ones can't be effectively upgraded (consequence of using obsolete ini file apis). 2023-05-28 14:22:09 -04:00
SimonAfek 3cefa5d78e
Update deprecated GitHub actions v2 (#666)
* Windows CI: Update deprecated github actions

* build_interface.yml: Update actions

* release_tarball.yml: Update checkout action

* build.yml: Update actions
2023-05-20 16:33:23 +01:00
SimonAfek fadd3b6e63 Windows CI: Update deprecated github actions 2023-05-10 13:56:54 +01:00
rogerman bf344e9a3e SoftRasterizer: Perform all calculations using fixed-point math instead of float-based math.
- CommonSettings.GFX3D_TXTHack has been repurposed to switch between fixed-point math and float-based math.
- Fix various rendering bugs that were caused by a loss of Z precision introduced in commit 7751b59.
- In Pokemon Diamond/Pearl, the bug that caused random black dots to appear on the ground has been fixed.
2023-05-04 12:36:49 -07:00
zeromus 1dbbeba3a7 add another mic sample 2023-04-24 15:21:45 -04:00
zeromus 65ec088918 add mic samples. we're gonna start distributing these eventually. 2023-04-23 16:18:51 -04:00
zeromus 6b7559c71b fix alignment of tempMultiplyMatrix and currentMatrix[4] in GeometryEngineLegacySave. Fixes #657. It would be better to fix this perhaps by making NDSMatrix a type that has the alignas(16) put on it while inheriting from std::array<u32,16> perhaps, so this mistake is not possible? 2023-04-21 15:18:32 -04:00
zeromus c97ba8fb16 fix spurious RRX variant selection in several disassembly macros (fixes #652 maybe) 2023-04-10 11:43:46 -04:00
rogerman ab17945377 GFX3D: Obsolete and remove the VERT struct, since OpenGL, and SoftRasterizer are now both receiving their vertex data in fixed-point.
- Also remove the unused NDSVertexf struct. There shall be only one representation of the NDS vertex data, and that shall be the fixed-point values of NDSVertex.
2023-03-06 22:19:09 -08:00
rogerman 952585eaae SoftRasterizer: Read in vertex data data as fixed-point instead of as floating-point. 2023-03-06 21:39:57 -08:00
rogerman be88a0b4c3 Remove superfluous x/y/z names from Vector2s16, Vector2s32, Vector2s64, and Vector2f32 union data types, since it is extremely unlikely that these extra names will ever be used. Just use names "x" and "y", which are the most likely to be used for these kinds of 2-element vectors. 2023-03-06 21:27:47 -08:00
rogerman 4e1ce23982 SoftRasterizer: Do some minor refactoring and code cleanup, and also prepare SoftRasterizer to accept fixed-point vertex data. 2023-03-06 14:35:47 -08:00
rogerman 56251cafd1 GFX3D: Clean up the big-endian compatibility code. 2023-03-03 13:58:37 -08:00
rogerman 111292ff15 GFX3D / SoftRasterizer: Small refactor to use some of the new data types introduced in commit cda8cb5.
- Also make SoftRasterizer's framebuffer out-of-bounds width check more robust.
2023-03-03 13:02:04 -08:00
rogerman 90c8411cbf GFX3D: Fix clear color on big-endian systems. (Regression from commit 97848fc.) 2023-02-28 01:34:27 -08:00
rofl0r dcd1072800 CI: limit autoconf build to 8 processes
hopefully will prevent the OOM killer from kicking in.
2023-02-28 03:07:43 +00:00
rogerman 1daebcd670 Silence some compiler warnings. 2023-02-27 16:36:08 -08:00
rogerman cda8cb5686 Core: Move low-level vector, vertex coordinate, and color data type declarations into types.h so that they can be used universally. Also update the data type names to be more descriptive and have better consistency.
- Add SIMD-float32 data types, and also add macros to track SIMD data-type availability.
- Also fix some bugs where 3D would fail to render on big-endian systems. (Regression from commit a67e040.)
2023-02-27 15:39:17 -08:00
rogerman d9be9c6bf6 Cocoa Port: Silence some compiler warnings. 2023-02-25 12:11:22 -08:00
rogerman a7bdd1e3a9 GFX3D: Remove the mistaken addition of color clamping when converting fixed-point vertex colors into floating-point. Fixes the proper coloring of Princess Peach in the opening sequence of Super Mario 64 DS. (Regression from commit 7751b59.) 2023-02-24 16:01:14 -08:00
rogerman fac70ce98b OpenGL Renderer: Use the fixed-point vertex list data instead of the floating-point based one, alongside other tune-ups.
- To determine polygon facing, use GFX3D's CPoly.isPolyBackFacing instead of using GLSL's gl_FrontFacing. This eases OpenGL version requirements and improves older GPU compatibility a little.
- Also fix a bug where GPUs that support FBOs, but not shaders, were unable to read out their framebuffers properly.
2023-02-24 13:49:07 -08:00
rogerman 37683a708e GFX3D: Y-sorting and writing out vertices to a save state are now handled using fixed-point instead of floating-point, where appropriate. 2023-02-23 13:12:13 -08:00
rogerman 7751b59882 GFX3D: Polygon clipping, viewport transformation, perspective correction, and face calculations are now done in fixed-point instead of floating point. 2023-02-22 22:07:37 -08:00
rogerman e1969c470b GFX3D: Vertex post-processing has been moved from the 3D renderers to GFX3D.
- Specifically, viewport transformation, face calculation, and face culling are now handled in GFX3D, and are now standard behaviors for all 3D renderers. This reorganization makes more sense since the 3D renderers are primarily responsible for rasterization and framebuffer post-processing, rather than for processing geometry.
- As a positive side-effect, the OpenGL renderer gains a small performance improvement as well as better accuracy in face culling.
2023-02-19 20:23:44 -08:00
rogerman 5457932d75 OpenGL Renderer: Fix bug where the Depth L-Equal Polygon Facing option would fail to become enabled when running OpenGL 3.2 or later. (Regression from commit ab38d17. Note that this bug does affect the 0.9.13 release build.) 2023-02-18 16:31:38 -08:00
rogerman cf75e26353 OpenGL Renderer: Silence compiler warnings. 2023-02-18 16:21:44 -08:00
rogerman 97848fce8c GFX3D: Move some last bits of static data floating around in gfx3d.cpp into the GFX3D struct, and then make the instantiation of the struct itself static. 2023-02-18 13:37:17 -08:00
rogerman 92d662cb71 GFX3D: Fix longstanding potential overflows related to polygon lists by reducing POLYLIST_SIZE from 20000 to 16383.
- Historically (ever since commit b1e4934 and commit d5bb6fd), VERTLIST_SIZE (based on POLYLIST_SIZE) could reference an index over 66535, but POLY.vertIndexes has always been an unsigned 16-bit value with a max value of 66535, making for a potential overflow. In practice, an overflow has never happened in the past 15 years because a hardware NDS has a limit of 6144 polygons (or 24576 vertices), and that even a VERTLIST_SIZE of 80000 is way more than plenty to accommodate that. Rather than increasing POLY.vertIndexes to 32-bit, it makes more sense to reduce POLYLIST_SIZE to 16383 to keep VERTLIST_SIZE below 66536. Even with this change, POLYLIST_SIZE and VERTLIST_SIZE should be more than plenty in practice.
- Also, now that we're performing polygon clipping for all client 3D renderers (ever since commit e06d11f), we're finally accounting for the fact that the clipped polygon list size is larger than POLYLIST_SIZE. Client 3D renderers have been updated to now reflect this change and avoid theoretical overflow issues that have never actually happened in practice.
2023-02-18 10:54:02 -08:00
rogerman 86b990f68a GFX3D: The shininess table is no longer a part of SWAP_BUFFERS.
- Since the shininess table is only ever used for vertex generation, it makes no sense for the table to included for the rasterization step. The shininess table has been moved to the NDSGeometryEngine class, which is a class dedicated to just vertex and polygon generation. This reorganization seems more sensible.
2023-02-17 18:32:42 -08:00
rogerman 4a95e9b8d1 GFX3D: Reorder members of the GeometryEngineLegacySave struct to better reflect the actual order of data in the existing save state format.
- Also rename some matrix-related members for better clarity.
2023-02-17 14:01:24 -08:00
rogerman d0d23cce7e GFX3D: Attempt to fix an MSVC compiling issue. (Related to commit 5d6e866.) 2023-02-17 12:00:27 -08:00