Commit Graph

1170 Commits

Author SHA1 Message Date
stephena 3c93be914a First pass at making the debugger be asynchronous from the debugger parser,
meaning that if a command is running, it can be interrupted, and Stella
doesn't lock up in the process.  It all feels like sort of a hack, but
for now it's the best we can do.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1183 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-05 22:05:35 +00:00
stephena dcb74722ad Second pass at optimizing the GP2X framebuffer rendering. There's still
at least one more optimization to make after this :)


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1182 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-05 21:55:15 +00:00
stephena 84781e064a A few more optimizations for the GP2X rendering code.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1181 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-05 14:53:26 +00:00
stephena 2a8956ebae Oops, another copy/paste typo.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1180 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-05 03:04:14 +00:00
stephena 918d55ab5a Fixed a typo from copy & paste.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1179 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-05 03:01:49 +00:00
stephena 718e54c706 Fixed bug in OSX OpenGL handling. Now OpenGL mode works again!
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1178 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-04 20:14:06 +00:00
stephena 0bf5e843bc First pass at optimizing the FrameBufferGP2X rendering code. Since the
hardware in this device is a known quantity and is using a hardware surface,
perhaps we can take advantage of that.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1177 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-04 19:43:26 +00:00
stephena c973c3d968 This code is a little more compact and readable.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1176 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-04 19:01:39 +00:00
stephena dddbbfdfdf Added some OpenGL options to FrameBufferGL that only exist on SDL 1.2.10
or greater.  I'm hoping that one older systems, the code will still run
and just ignore these new options.

Added commandline argument '-gl_vsync', which enables v-sync'ed updates
for OpenGL, if it's available (see above).  Also added a setting for
this in the VideoDialog.

Fixed OSX OpenGL handling so that it doesn't specify an OpenGL library name,
and updated FrameBufferGL to use the default name in that case.  OSX users
will probably need to reset their settings file for this to take effect.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1175 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-04 18:54:51 +00:00
stephena 1cbef3f8f9 I finally got my hands on an Intel Mac, so this is the first time StellaOSX
has been compiled for at least 4 months.  At least it now compiles again
(but OpenGL mode doesn't seem to be working).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1174 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-04 16:15:42 +00:00
azaballa d65125fedd GP2X doesn't require zoom. Thanx Steve.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1173 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 22:49:25 +00:00
azaballa 80b76fec6c GP2X can finally handle zoom2x.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1172 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 20:26:11 +00:00
azaballa 0eff44fa5c Changed a few things to accomodate the new SDL libs.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1171 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 19:19:35 +00:00
stephena 67f631e697 Separated out RectList from FrameBufferSoft, since FrameBufferGP2X also
needs it.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1170 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 17:57:54 +00:00
stephena b4531c331a Crap, a segfault bug crept in with the last commit.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1169 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 01:24:34 +00:00
stephena f48ea59ca6 OK, second pass at FrameBufferGP2X class.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1168 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-03 01:13:45 +00:00
stephena 8ef6d7032e Cleaned up the DebuggerParser class in preparation for user-interrupible
commands.  It's not quite working right now.

Added preliminary GP2X framebuffer class, so the GP2X can optimize
for that system.  It's based on FrameBufferSoft, and doesn't really
do much differently right now.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1167 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-02 23:25:55 +00:00
stephena 78f33efe78 Made changes in EventHandler state not re-create the FrameBuffer object.
The only time the FrameBuffer is (re)created is when one doesn't exist
(at the start of program), or when toggling between software and OpenGL
mode.  Hopefully this will fix the problems in the GP2X port wrt the
new SDL libs.  But even if it doesn't, I think it's a cleaner way of
doing things ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1166 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-02 00:43:50 +00:00
stephena 4c8743b04e Some fairly major changes to the Properties handling. Added a 'Default'
button to GameInfoDialog, which basically resets ROM properties to
built-in (compiled) defaults, and removes the entry from an external
stella.pro file (if it exists).  A ROM reload is still necessary
for these settings to take effect.

Removed 'Alt-s' properties merging shortcut, since it does the same
as clicking OK in GameInfoDialog, and there should be only one way of
doing that.

Fixed bug in UI where pressing state-change keys (Ctrl, Shift, etc)
would be interpreted as characters.

Added ROM properties for "Strat-O-Gems Deluxe".


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1165 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-12-01 18:30:21 +00:00
azaballa e3c0ee39ff Disabled SDL Cursor by default for the GP2X.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1164 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-29 20:01:56 +00:00
stephena 7ac52b8609 Adding missing OK and Cancel events to CheatCodeDialog.
Tied 'OK' and 'Cancel' events to closing the About and Help dialog boxes.

Fixed bug where menu event mappings weren't being reset on default.

Fixed bug where some characters could be mapped to an event, but didn't
actually do anything.  This is related to Unicode issues, and may fix
problems that non-ASCII users have been experiencing.

Fixed issue with joystick buttons/axis events not being processed in
PopUpWidgets.  This fixes the problems experienced by GP2X users, where
selecting a popup menu seemed to lock Stella (in actual fact, it was
still running, waiting for input).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1163 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-29 18:22:56 +00:00
azaballa 018e02d7e6 Fixed some tabbing(cosmetic) issues.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1162 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-29 01:29:28 +00:00
azaballa 36f4122d7d Updated button mapping to incorporate the new UI events. Updated configure to fix a linking issue.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1161 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-29 00:24:57 +00:00
stephena cc5afaba11 Added 'UIOK' and 'UICancel' menu events to the core, and made them
remappable in the InputDialog.  These are a shortcut for the OK and
Cancel buttons in certain Dialog boxes, instead of having to tab to
the respective buttons.  By default, 'UICancel' is mapped to Escape,
and 'UIOK' is not mapped to anything.

Hopefully fixed the issue with the GP2X window not being cleared
when switching between emulation modes.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1160 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-28 21:48:56 +00:00
stephena 08863d0ba9 Fixed palette not being loaded when entering the debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1159 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-27 22:57:09 +00:00
stephena c833852131 Fixed bug where screen wasn't being cleared after changing emulation modes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1158 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-27 21:02:45 +00:00
stephena b7e6bed91b Make sure the first item in the list is always selected in ROM browse
mode.  It was actually always supposed to do this, but a one-line
bug prevented it (thanks to Alex and TelcoLou for this).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1157 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-27 14:52:51 +00:00
stephena 9fa5ea44ab Changed to standard C++ getenv/putenv calls instead of SDL-specific
ones (reported to not compile by Alex, the GP2X maintainer).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1156 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-27 02:18:47 +00:00
stephena 563ba6b24b Added writing of text tags to PNG snapshots. For now, it only saves
the version of Stella used, as well as some ROM info (name, md5, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1155 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-26 16:58:21 +00:00
stephena d536cb06ea Major update to the palette support. Internally, all palette info
now belongs to the Console class.  A single user definable palette
can now be automatically loaded.  This new palette file must be
named 'stella.pal', and located in the app base directory
($HOME/.stella for Linux, installation dir for Win32).

The new palette file must be at least 768 bytes (only the first 768
bytes are used).  The first 384 bytes are 128 red-green-blue 8-bit
values, or 24-bits per pixel for NTSC.  The next 384 bytes/128 colours
are the same, except for PAL.  The PAL colour-loss palette is automatically
calculated from these, so it's not necessary to do so in the palette file.

Added 'user' to the list of options that can be specified for '-palette',
and also added the option to the VideoDialog.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1154 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-25 01:34:35 +00:00
stephena d5ecdd6f66 In the process of adding external palette support (and with the help of
Brad), I realized that the PAL 'colour-loss' effect wasn't being done
with the 'original' and 'z26' palettes.  This is now fixed.

Changed a few ROMs from PAL to PAL60.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1153 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-22 02:39:31 +00:00
stephena e1076ea369 Added "PAL60" support, which AFAIK is simply a PAL screenmode with a 60Hz
refresh rate.

Updated properties for AStar and Ladybug ROMs which have PAL60 versions.
Still TODO (now that the infrastructure is in place) is update all other
ROMs that might be PAL60.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1152 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-19 20:59:30 +00:00
stephena 8ce5a7cdab Removed 'paddle' as a saved setting (it can still be set from the
commandline or by pressing Ctrl-0/1/2/3).  Also removed all related
settings from the settings dialog.

Added a ROM property called 'Controller.PaddleNo', which specifies
which paddle to use for a particular ROM (not all ROMs use paddle 0
be default).

Large update of the ROM properties, based on info from z26.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1151 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-19 00:48:55 +00:00
stephena 75e050a34b Removed 'TEXTURES_ARE_LOST' define, since the core framebuffer code
no longer uses that scheme (it always re-creates the OpenGL context).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1150 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-18 13:52:07 +00:00
stephena 453b31cb51 First pass at removing libpng support from the OSX build process. Of
course, I still can't test this until I find an OSX machine ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1149 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-18 13:34:26 +00:00
stephena d5a1bbda13 Some further restructuring of the Scaler stuff, and integration into
the VideoDialog.

Updated properties for Picnic and Philly Flasher.

Completely removed all libpng stuff from OSX.  Still TODO is find a
system to compile the OSX version, and test the actual changes.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1148 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-18 13:29:12 +00:00
stephena 76eb15a8be Made all statefiles be named according to their romname as given in
the properties file (instead of using md5sum).  The md5sum naming
is no longer needed, and made it very difficult for users to
distribute the state files.

Similar to above, removed ability to name snapshots according to
md5sum, and instead use romname.  Consequently, removed all
references to 'ssname' commandline argument and GUI related
config options.

Added ability to specify a different 'base directory' for settings,
state files, etc.  Normally, this is chosen at compile time, and is
set to $HOME/.stella/ for Linux and OSX, and the current dir for Win32.
Now, if you set the 'STELLA_BASEDIR' environment variable, it will
use that path instead.  Note that this must be set every time Stella
is run, since there's no way to save it to a settings file (since
the settings file location is dependent on what the env var contains).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1147 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-13 00:21:41 +00:00
stephena 8757c935c2 Fix for Snapshot showing old messages in Windows (and probably OSX as
well).  Hopefully this bug is fixed for good.

A few updates for the Win32 VC project.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1146 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-11 20:20:16 +00:00
stephena 90723af108 Minor reworking of the Snapshot class, making the savePNG method static.
There was really no need to have this as an object, since it's all static
code anyway.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1145 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-10 06:14:14 +00:00
azaballa 12d9de32cc Cleaned up some missed PNG references. Thanx for killing the dependency. =)
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1144 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-09 07:58:39 +00:00
stephena 14e7818fdf Completely removed the PNG library dependency from Stella. I'm amazed
at how easy it was to just write the PNG directly; it takes roughly the
same amount of code as when interfacing with the PNG library!  One
less dependency is always a good thing, since some systems might not
have it installed by default.

For now, the Linux side of things is complete (configure script, etc).
Still TODO is check the Win32 project file, and rework the OSX stuff
(OSX had the full libpng sources embedded in src/macosx).  I suspect
this will fix the bugs recently reported when compiling Stella on
Intel-based Macs.

Added a freedesktop.org compliant stella.desktop menu entry, which is
now installed as part of 'make install'.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1143 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-09 03:06:42 +00:00
stephena 340b0770b2 Added 'fastscbios' commandline boolean argument, which affects how fast
the vertical bars are drawn in the SuperCharger BIOS roms.  When this is
set to true, each bar is drawn as fast as possible, to speed up loading
of SC BIOS.  Requested by various people on AtariAge.

Still TODO is add a GUI checkbox for this (figure out exactly where in
the settings this item belongs).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1142 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-08 00:09:53 +00:00
stephena a4eea07b85 Added updated configure system from Debian package.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1141 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-06 16:27:46 +00:00
stephena 0c5beed367 Fixed another long-standing GUI crash in software mode when switching
to the debugger (incorrect width for DataGridOpsWidget).

Added 'autoslot' commandline argument.  When set, pressing the save state
button (by default F9) will save state to the current slot, then
automatically switch to the next higher slot.  I still need to add this to
the GUI settings somewhere.  This was a request from N. Strum of AtariAge.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1140 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-06 00:52:04 +00:00
stephena ba82080839 Turned ppblend into a ROM property named 'Display.PPBlend', which means
that blending is now per-ROM.

Added slider widget to GameProperties dialog to change the phosphor
blend amount.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1139 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-04 19:38:25 +00:00
stephena 1fd458c9e9 Oops, this code will only work in SDL 1.2.11, and I haven't added logic
to test for that version yet.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1138 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-03 16:55:44 +00:00
stephena 121f75314b Scaler support is now selectable from configure, and defaults to off
(no more editing the configure script).  It's still not working, though.

Added more options to the AudioDialog settings, allowing to set output
and TIA frequency, and volume clipping.  These are the same options that
were always available on the commandline; they're now exposed to the GUI
as well.

Fixed segfault when launching Stella without a stellarc file.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1137 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-11-03 16:50:19 +00:00
stephena c7a073c6a2 Some configure work:
- removed TEXTURES_ARE_DIRTY logic, and just recreate the GL textures
    when a screenmode changes
  - enable checking for machine type and if nasm is available
  - logic to enable scaler mode only when in OpenGL mode (still not complete
    and defaults to off)

First pass at adding scaler code to OpenGL.  Still much work TODO,
but the C version is working correctly (asm is causing crashes,
haven't figured out why).  GL quad coordinates aren't properly
set yet, so the image always appears in the upper left corner, and
is not scaled to the window size.  CPU usage is also quite high,
but I'm on a 1GHz laptop with i950 GL, so that may explain it.

Fixed long-standing bug in software rendering, where switching to a
lower-res screen while a message is being displayed would cause a
segfault.

Large refactoring of mainSDL.  Specifically, OSystem now owns all
the subsystems except for Settings, taking responsibility for creating
and destroying them.

Properties fixes for 'Tomarc the Barbarian' and 'Gyruss'.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1136 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-10-22 18:58:46 +00:00
stephena e3b36b202c More work on the new scaler infrastructure, and a fix for incorrectly
positioned GUI elements in emulation mode (I was a little too eager with
code pruning).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1135 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-10-16 01:09:00 +00:00
stephena 8925bf8b36 Fixed long-standing crash when switching zoom/scaler levels in the software
framebuffer.  Fixed getScaler() logic to only use scalers that are actually
available in a particular mode.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1134 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2006-10-14 22:17:27 +00:00