Commit Graph

6126 Commits

Author SHA1 Message Date
zeromus 2c1360dec5 fix #97 - increasing matrix stack cursor size to 6bits caused garbage to get masked into GXSTAT since there had been no &31 to select only the needed 5 bits 2017-09-29 14:47:15 -05:00
rogerman d37ef1ff95 Cocoa Port: Copying the contents of the display window via Edit > Copy now copies the actual contents of the display window instead of directly copying the NDS screens with a generic vertical layout. 2017-09-25 21:21:51 -07:00
rogerman 70c69a46d3 OpenGL Renderer: Fix a bug where the behavior of translucent polygons can become undefined if the frame contains nothing but translucent polygons. Fixes a graphical glitch in Grey's intro scene in Mega Man ZX Advent. (Regression from commit 1742114.) 2017-09-23 21:32:34 -07:00
rogerman 1742114fcd OpenGL Renderer: Reset the current polygon's OpenGL states to the last opaque polygon whenever the zero-destination-alpha-pass is performed. Fixes a graphical bug in MegaMan ZX Advent, where the explosions from the boss in Grey's first level will render incorrectly. (Regression from commit eea54a7.) 2017-09-22 17:25:01 -07:00
rogerman f521ab1164 Cocoa Port: Refactor the hardware mic stuff out of CocoaDSController and into ClientInputHandler. 2017-09-21 00:33:28 -07:00
rogerman f8bbbec0ae OpenGL Renderer: Fix possible crash that may occur if the 3D framebuffer is used before the 3D renderer has a chance to render at least once. (Partially addresses #59.) 2017-09-19 17:47:48 -07:00
rogerman 4ea08792cb Cocoa Port: Fix bug where the ROMInfoPanel was misaligning the locations of info sections. 2017-09-19 15:49:22 -07:00
rogerman aa04c8f233 Cocoa Port: Better guarantee that display views will always be assigned a display ID. 2017-09-19 14:47:55 -07:00
rogerman 830dd0d78c Cocoa Port: Give user feedback for when the emulation gets halted internally.
- Also be more consistent when recovering from an internal emulation halt.
- Also apply enabling the external BIOS, external firmware and firmware boot settings at load/reset time instead of at frame time.
2017-09-19 12:59:44 -07:00
zeromus 1c59441697 fix bug in sthread_isself (fixes #34) 2017-09-17 04:05:17 -05:00
zeromus c5cea732fa update rthreads.c from upstream 2017-09-17 04:02:14 -05:00
rogerman fda9fc2a89 Cocoa Port: Reduce threading overhead for framebuffer fetches and SPU_Emulate_user().
- Framebuffer fetches no longer run on a CocoaDSThread, but instead uses a pthread directly. This can be done since framebuffer fetching only serves one function and always receives the same execution message, making a full CocoaDSThread a waste.
- SPU_Emulate_user() is no longer called on a separate thread, and instead is called in the emulation thread directly. For the typical SPU use case (SPU Sound Synchronization w/ Advanced SPU Logic), SPU_Emulator_user() becomes negligible, and so the threading overhead becomes unnecessary. In the use case where Dual SPU Synch/Asynch is used, Advanced SPU Logic is almost always disabled with it, and so the penalty of calling SPU_Emulator_user() on the emulation thread will be more than compensated by the performance increase of turning off Advanced SPU Logic.
- Also do some code cleanup/refactoring here and there.
2017-09-16 18:08:07 -07:00
rogerman 8f2c85fe86 Cocoa Port: Remove some extraneous properties from DisplayWindowController since these same properties are handled elsewhere. 2017-09-16 02:36:22 -07:00
rogerman 4957d7be5b Cocoa Port: Rework how Metal display views flush to screen, improving their overall performance.
- Fix a bug where Metal display views can block emulation execution if the user very quickly spams inputs while the input HUD is shown.
- Metal display views are no longer frame capped -- they can now run to their fullest performance potential, as fast as the host hardware will allow. This behavior is now consistent with OpenGL display views.
- As a side-effect, non-layer backed OpenGL display views also have a performance improvement.
2017-09-16 00:13:52 -07:00
zeromus 759a039e25 handle powered-off geometry engine more sensibly. involves commit 66b5da1c and issue #31, intended to fix ZX advent. fixes #58. 2017-09-15 09:57:16 -05:00
rogerman d33faecd12 Cocoa Port: Create new DisplayView objects in code instead of creating them implicitly through the nib. 2017-09-13 14:48:19 -07:00
rogerman c94f353f2a Cocoa Port: For Metal display views, in -renderDrawable, separate buffer updates from encoding commands in an effort to try to reduce the hold time on the vended drawable as much as possible. 2017-09-12 00:50:57 -07:00
rogerman d0f16193c5 Cocoa Port: Refactor out more input-related stuff into some new files -- ClientInputHandler.cpp/.h. 2017-09-11 23:32:30 -07:00
rogerman cb4ecbe17e Cocoa Port: Do some refactoring to remove extraneous connections in EmuControllerDelegate. 2017-09-11 15:26:37 -07:00
rogerman 221fa5f72b Cocoa Port: Add support for reporting inputs in the HUD.
- Also do a bunch of code refactoring.
2017-09-11 09:41:54 -07:00
rogerman 17ff2b2d6e vfat.cpp: Silence a couple of compiler warnings. 2017-09-09 13:00:35 -07:00
rogerman 4cfa910e75 Cocoa Port: NEW FEATURE - Users can now apply custom colors to individual HUD line items. 2017-09-05 13:12:31 -07:00
rogerman 2b9bc2509a Cocoa Port: Additional tweaks to the new turbo settings UI. (Related to commit af22153.) 2017-09-04 09:54:35 -07:00
rogerman af22153f5c Cocoa Port: NEW FEATURE - Add the ability to set up custom frame-by-frame press/release state patterns for turbo. 2017-09-04 09:33:11 -07:00
rogerman d1ac719b5c Cocoa Port: Fix UI issue where status bar on display windows would no longer show the mic gain control. (Regression from commit 3bf295f.) 2017-09-04 08:09:48 -07:00
rogerman ccaefb18bc Cocoa Port: Fix UI issue where the Input Preferences window may not be automatically assigned as the first responder. (Regression from commit 1e9b179.) 2017-09-03 14:25:25 -07:00
rogerman f67f959fe3 Cocoa Port: Retrieve both pending and applied NDS inputs post-NDSExec().
- Also do some minor code cleanup on some input-related stuff.
2017-09-01 16:38:06 -07:00
rogerman a86539eb1c Cocoa Port: Do some refactoring on reading the client-side inputs.
- Also make calculating the mic level average more efficient, as well
as updating the mic level average every 8th frame instead of every
frame.
2017-09-01 00:33:54 -07:00
Roger Manuel b4650e4083 Merge pull request #94 from atsampson/master
Update remaining stub versions of mic_savestate/loadstate. Fixes #95.
2017-08-31 01:16:40 -07:00
rogerman fd6ed7b518 Cocoa Port: Synchronize access to ClientDisplayView._hudString. 2017-08-30 15:34:58 -07:00
rogerman db4982f4bc Cocoa Port: Continue refactoring cocoa_core.mm.
- Also fix a small off-by-one error in slot1_Change().
2017-08-30 15:20:08 -07:00
rogerman e29e825d27 Cocoa Port: Report newer options in the Support Requests and Bug Reports pages to reflect the current feature set.
- Also update the URL for the Bug Report webpage from sourceforge.net
to github.com.
2017-08-29 17:16:19 -07:00
rogerman abebaebdef Cocoa Port: Continue refactoring the emulation execution loop code to be less port-dependent. 2017-08-29 15:14:24 -07:00
rogerman 3bf295f4ce Cocoa Port: Fix bug where Lion-style full screen failed to work on OS X Mavericks and Yosemite. 2017-08-28 19:36:55 -07:00
rogerman 1e9b179bf4 Cocoa Port: Begin refactoring some of the emulation execution loop code to be less port-dependent.
- Also clean up some UI code with switching app preferences views when
running OS X Leopard.
2017-08-28 17:30:19 -07:00
rogerman a05e03e2cc OpenGL Renderer: When running a GPU Scaling Factor of 3x and 4x, increase the MSAA sample size limit from 8xMSAA to 16xMSAA. 2017-08-27 14:07:13 -07:00
rogerman 2379dc1e41 OpenGL Renderer: Make the MSAA sample size limit based on the framebuffer size instead of being fixed at 8xMSAA.
- The MSAA sample size limit is now based on the following sizes:
1x Native Resolution - 32xMSAA
2x Native Resolution - 16xMSAA
3x-8x Native Resolution - 8xMSAA
9x and greater Native Resolution - 4xMSAA
2017-08-26 22:41:53 -07:00
Adam Sampson e58fb84707 Update remaining stub versions of mic_savestate/loadstate.
11cf901336 changed most of these but
missed these three.
2017-08-26 15:32:14 +01:00
rogerman e6d5a8fbe1 Windows Port: Increase the maximum GPU Scaling Factor from 5x to 16x. (This should be safe on the vast majority of GPUs out there, but if we find out that this ends up being unsupported on many GPUs, the max scaling factor may have to be reduced back to 5x. This will need additional testing.)
- Also do some minor code cleanup here and there.
2017-08-25 18:53:07 -07:00
rogerman 823e9edf7f Windows Port: Fix compiling on Windows. (Regression from commit 11cf901.) 2017-08-24 15:28:46 -07:00
rogerman 11cf901336 Major code cleanup across the board, mostly involving interactions with EMUFILE.
- Function/method parameters for EMUFILE objects are now passed by
reference instead of passed by pointers, where appropriate. This is
true for the vast majority of EMUFILE usage.
- Eliminate duplicate little-endian read/write functions in
readwrite.cpp. Use the equivalent methods in EMUFILE instead.
- Completely standardize the design patterns and usage of the various
little-endian read/write methods. Should help stabilize interactions
with save state files, as well as try to make save states
cross-compatible between big-endian and little-endian systems.
- Replace EMUFILE fread()/fwrite()/fputc() calls with equivalent
size-specific methods where applicable.
- Misc. code readability and stability improvements.
2017-08-24 15:14:25 -07:00
rogerman e17e1bd0af Cocoa Port: Minor tweaks to some UI elements to eliminate some build warnings. 2017-08-23 02:37:37 -07:00
rogerman c52b5702ed Cocoa Port: Change InfoPlist.strings format from UTF-16LE to UTF-8.
- Also add macosx_10_5_compat.cpp back into the normal OS X build of
the Xcode Latest project. It’s still needed for compatibility on OS X
10.5 Leopard for x86/x86-64. (Don’t know how this got disabled — it
just somehow mysteriously did.)
2017-08-23 01:47:44 -07:00
rogerman 3a63db2086 Cocoa Port: Do some minor code cleanup. 2017-08-22 21:31:28 -07:00
rogerman 2746427dd7 Colorspace Handler: Fix more RGBA8888 and RGBA6665 conversions for Altivec. 2017-08-22 15:50:03 -07:00
rogerman c7b9ecfc52 Cocoa Port: Tiny code consistency change. 2017-08-22 13:57:12 -07:00
rogerman e4f935743c GPU: Clean up and optimize the BG mosaic code. 2017-08-21 19:31:41 -07:00
rogerman da6c79c6bd GPU: When calculating the VRAM pixel location using MMU_gpu_map(), replace division and mod instructions with bitshift and bitwise AND instructions. Should help older compilers that don't know how to optimize the division/mod instructions into bitshift/bitwise AND instructions. 2017-08-21 08:23:12 -07:00
rogerman f02210bfdb GPU: Try to clean up GPUEngineBase::_SpriteRenderPerform() a little bit. 2017-08-19 20:21:09 -07:00
rogerman a9f2e53c25 GPU: Be consistent with how we apply the sprite window flags.
- Now applies the sprite window flags consistently between rotozoomed
and non-rotozoomed modes.
- Applying the sprite window flags in rotozoomed modes now ignores
sprite priority as intended.
2017-08-19 12:07:48 -07:00