Commit Graph

3561 Commits

Author SHA1 Message Date
Stephen Anthony fbb73b72f1 Erase old contents of RGB buffer when toggling phosphor and Blargg
effects (fixes #175).

Right idea, but I always forget that memset operates on bytes,
but the RGB buffer contains uInt32 (so multiply by 4).
2017-07-13 19:27:21 -02:30
Stephen Anthony 626ff450d9 Added ability to change debug colors from "Video Settings".
Moved ColorWidget from src/debugger/gui to src/gui, since it needs to be
compiled even when the debugger is disabled.

Minor code refactoring.
2017-07-13 18:40:42 -02:30
Stephen Anthony d9f52599dc Marked BUS scheme as experimental per authors request. 2017-07-12 18:07:40 -02:30
Stephen Anthony 87c1d12d1d Fixed dynamic setting of phosphor blend to not wraparound when reaching 0. 2017-07-12 16:16:41 -02:30
Stephen Anthony 0d1481cb9d Revert behaviour of TIA read from write-only addresses to match
Stella 4.x (fixes #173).
2017-07-11 17:18:56 -02:30
Stephen Anthony e9acf1f1e8 Updated various docs for impending 5.0 release.
Finalized state file format at 5.0.0.0.
2017-07-09 22:56:16 -02:30
Stephen Anthony a6fe6e0bd8 Oops, forgot to remove some documentation editing typos. 2017-07-09 22:43:09 -02:30
Stephen Anthony d613173cd7 The default phosphor blend level can now be set globally (fixes #144).
Added new 'tv.phosphor' commandline argument to accomplish the above,
and associated UI item in Video Settings.

Updated docs for 'tv.phosphor' and 'tia.debugcolors'.  More work is
needed on this, since I need to add screenshots for this new functionality.
2017-07-09 22:40:06 -02:30
Christian Speckner aa5be284cb Add a note on ystart autodetection. 2017-07-10 00:49:09 +02:00
Stephen Anthony 7f6637a802 Updated ZLIB and PNG libraries to latest released versions. 2017-07-09 16:49:17 -02:30
Stephen Anthony fadf9d5535 Updated ROM properties to RomHunter version 13. 2017-07-09 15:48:10 -02:30
Christian Speckner 12dad0543e TIA tab: document old / new registers and delay queue. 2017-07-08 00:58:39 +02:00
Stephen Anthony 10c53bce89 Make 'listtraps' less verbose (fixes #157). 2017-07-06 21:05:52 -02:30
Stephen Anthony 7f2b6a8983 Debugger documentation and screenshot updates. 2017-07-06 20:55:01 -02:30
Stephen Anthony f177aed814 Fix debugger trap documentation (fixes #156 from #164) 2017-07-06 19:45:12 -02:30
Stephen Anthony e1bc5c92e4 Trakball documentation fixes and other minor updates (from issue #164). 2017-07-06 19:30:11 -02:30
Christian Speckner 2111340785 Fix compile with gcc 5.4.0. 2017-07-06 00:00:05 +02:00
Stephen Anthony 6d4a98d735 Updated version for next pre-release. 2017-07-05 18:04:27 -02:30
Stephen Anthony 970804b9f3 Optimization: modify RGB pixel data locally instead of calling functions.
This is allowed, since after analyzing the code, we see the pixel format
will always be ARGB8888 mode, so we can hard-code the logic to do the
conversion.

This leads to a measurable performance improvement, since we eliminate
3 function calls per RGB colour lookup.  And the calls themselves involved
IF statements and various other shifts that weren't needed.  Assuming
normal phosphor mode with 160x210 pixels, this saves 100,800 function calls
per frame!
2017-07-05 14:48:43 -02:30
Stephen Anthony ea59fdd3f2 Code cleanups, commenting fixes, etc for Blargg-related code. 2017-07-05 14:11:41 -02:30
Stephen Anthony 6da07d8dc7 Optimization: eliminate redundant access through a struct. 2017-07-05 13:06:44 -02:30
Stephen Anthony 09af9d09a5 Finally fixed issue #75 (phosphor mode now works with Blargg). 2017-07-05 12:48:39 -02:30
Stephen Anthony 1d293df782 Updated changes for system label lower vs. upper case. 2017-07-04 20:24:19 -02:30
Stephen Anthony d88969adcb Store and lookup system labels (aka, equates) in case-insensitive manner.
This fixes a bug in the debugger parser, where typing (for example)
'trap swchb' doesn't work but 'trap SWCHB' does.
2017-07-04 19:50:32 -02:30
Stephen Anthony 087fccd29f Updated OSX project file for recent class additions.
Eliminated some dead code.
2017-07-03 19:16:14 -02:30
Stephen Anthony 588cd82be9 Updated Visual Studio project file for recent class additions. 2017-07-02 21:08:12 -02:30
Stephen Anthony 7b57d52260 My neverending quest to protect against raw pointers.
Changed many 'const char* ...' to 'const char* const ...'.
2017-07-02 20:46:27 -02:30
Stephen Anthony 9972af022a Fairly huge refactoring of the cart autodetection code.
This has been in patch form for about a year, and I'm finally
getting around to applying it.  Basically, we separate the Cart
class into 3 classes:
  - Cart: stuff specific to cartridge emulation
  - BSTypes: various bankswitch types, both as enum and strings
  - CartDetector: actual bankswitch auto-detection code

Also made more use of smart pointers, and added const in a few
more places.

I promise to get back to the phosphor stuff soon.  This is just
to clear my head a little.
2017-07-02 19:27:27 -02:30
Stephen Anthony 2e776b05b8 Introduced 'tia.dbgcolors' commandline argument, which allows to set
the fixed debug colors to user-defined preferences.  Note that there
are 6 registers (P0,M0,P1,M1,PF,BL), and the option takes a string
of 6 characters, where each represents a colour for the respective
positional register (ROYGBP are the choices).

I may add a UI item for this, but this is as far as I will go with
allowing user editing.
2017-07-01 19:54:02 -02:30
Stephen Anthony bd78683274 Rearranged some Blargg code, added comments, general cleanups.
For now, Blargg phosphor mode simply shows the same image as without phosphor.
This is a WIP, and if we can't get it finished for 5.0, it will be released as-is.

Phosphor blend now defaults to 0 in the base properties, and is converted to
50 before being passed to higher levels.  This needs to change when we
get to issue #144.
2017-06-30 14:10:14 -02:30
Christian Speckner fa76042790 Make sure that pending RDY is handled after stepping the CPU. Closes #155. 2017-06-24 00:35:17 +02:00
Christian Speckner 4515e79b4e Jitter only of frame height has changed for three or more consecutive frames. 2017-06-24 00:09:34 +02:00
Christian Speckner 628133d2dd Don't jitter if frame height differes by less than 3 lines. 2017-06-23 01:01:36 +02:00
Christian Speckner b30ca12731 Fix TIA info in debugger after RSYNC. 2017-06-22 01:08:22 +02:00
Christian Speckner ccafbf2bbd Tie state transitions directly to hctr in order to avoid edge cases during RSYNC. 2017-06-22 01:08:22 +02:00
Stephen Anthony 881dc86ab7 Oops, we need to handle the case where the controller is undefined. 2017-06-18 21:59:04 -02:30
Stephen Anthony 0bc8a928f0 Minor optimization in creating controller device in Console. 2017-06-18 21:52:59 -02:30
Stephen Anthony 21195c20cb Updated OSX project file for recent Blargg changes. 2017-06-17 20:51:32 -02:30
Stephen Anthony 705d42edd8 Updated Visual Studio project file for Blargg code changes. 2017-06-17 20:40:11 -02:30
Stephen Anthony 0f2df7e87b Fairly large reorganization of the Blargg NTSC TV effects code:
- converted many pointers to references
  - merged code from several files into one class
  - broke up some methods into more managable chunks

This will allow it to be easy to add the phosphor code during
NTSC TV emulation.
2017-06-17 20:08:36 -02:30
Christian Speckner 5da20a3a7a Savestate handling. 2017-06-15 17:16:06 +02:00
Christian Speckner bdded5e600 Wait for frame handling to stabilize before drawing. 2017-06-15 17:12:39 +02:00
Christian Speckner c2ce1943ca Fix loading and saving TIA state. 2017-06-15 16:13:07 +02:00
Christian Speckner cf55f5d413 Fix buggy blanking of line 0. 2017-06-14 12:37:57 +02:00
Stephen Anthony 861778f627 Fixed minor datatype difference in Blargg filtering. 2017-06-11 18:48:15 -02:30
Stephen Anthony 4a2e4b666c Started cleaning up Blargg code:
- Converted some stuff to C++
  - PAL colour-loss now works with Blargg enabled, but not yet for phosphor mode
2017-06-11 17:01:40 -02:30
Stephen Anthony a7b3ee4448 Debugger lst and sym files now follow ROM filename, not properties filename. 2017-06-11 13:02:47 -02:30
Stephen Anthony 44ead7b926 Updated std::map to use emplace instead of insert (optimization). 2017-06-09 14:50:11 -02:30
Stephen Anthony 3355183d03 Updated OSX build script for change from Deployment to Release. 2017-06-04 18:21:43 -02:30
C.W. Betts c9a3097946 Add some retina formats to Stella.icns. 2017-06-04 17:44:17 -02:30