Generalize regex and glob against `wx/config` scripts in
`Toolchain-cross-m32.cmake` to work on gentoo, which can append the
`-gtk3` suffix.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
For some reason on Ubuntu 14 (trusty) cmake translates `<INCLUDES>` in
`CMAKE_ASM_NASM_COMPILE_OBJECT` as a literal `INCLUDES` which produces
an error, remove it because we are not using it anyway.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Do not add the -fPIC (position independent code) compiler flag on 32 bit
x86 architectures because that breaks inline assembly, and some included
libraries like fex require inline assembly to work.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add a "Factory Reset" item to the Options menu, which calls
`DeleteAll()` on the config object, which actually deletes the config
file. After this the application is relaunched asynchronously without
parameters and the current instance is closed.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
When using msys ccache with a mingw ninja, the compiler fails to
execute.
Don't try to detect ccache when using the Ninja generator on msys2, it
can still be specified through cmake variables.
Do not check for the mingw ccache because it is broken and I will assume
not being used.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Conditionally compile out the code for the feature implemented in
16dd5d40 (which is the throttle and frame skip configuration for the
speedup button) for libretro, and use the old behavior of skipping 9
frames.
Affects GBA.cpp and GB.cpp .
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add Speedup / Turbo configuration panel which allows setting the
throttle or number of frames to skip for when the speed key is pressed
or turbo is enabled (which just presses the speed key.)
Throttle and frame-skip are mutually exclusive, throttle must be 0 (no
throttle) when number of frames to skip is non-zero. The dialog controls
handle this.
This is implemented in the core in GBA.cpp, GB.cpp and ConfigManager.
Two new options are added both in ConfigManager and in the wx options,
speedup_throttle and speedup_frame_skip, the defaults are:
```
speedup_throttle = 0 (no throttle)
speedup_frame_skip = 9
```
this was the original behavior.
Add support for unsigned ints to wx/opts.cpp for these and for throttle,
this requires a new validator wxUIntValidator to use them in spin
controls.
Clean up appearance of the throttle spin control in the General dialog.
Maximum throttle and speedup_throttle is 600, values much over 500 will
not behave differently from 0 on modern hardware.
Maximum frame skip is 30 at the moment.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Add wxEXPAND spacers to frame wxBoxSizer on the top and bottom around
the drawing panel so that panel is correctly centered if maximum zoom is
set.
Set proportion to 1 on the spacers and 0 on the panel so that both
centering with maximum zoom and full expansion work correctly.
Refactor frame OnSize event: pass a dummy userdata pointer to
distinguish resizing the frame from resizing the panel, and call
Layout() when the frame is resized.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Test for the -fdiagnostics-color=auto compiler option supported by gcc
and probably clang, and turn it on if it's available.
This option colorizes compiler warnings/errors/etc. when output to a
terminal.
Also fix a typo above when adding the -fopenmp flag.
1. EEPROM: move eepromInUse and eepromSize from EepromReset() to eepromInit()
to avoid re-initializing during a reset (makes item below redundant)
2. Remove gbaSaveType variable - this is now redundant due to change above
which probably was added for this reason since games using eeprom fails with
gamepak error after a reset.
3. Add labels to identify cpuSaveTypes
4. libretro: remove workaround for eeprom reset issue (#1), do not apply
custom gbPalettes if not running in GB, change vram size to 0x18000 in
memory map
Write `gopts.audio_dev` to the option `Sound/AudioDevice`.
Clear `gopts.audio_dev` when resetting the driver, because we cannot
assume anything about device enumeration order across sound drivers.
Signed-off-by: Rafael Kitover <rkitover@gmail.com>
Although this is a C++ option, some dists like ninja use CFLAGS instead
of CXXFLAGS for C++ code, and this becomes even more problematic with
XCode 10 which removes libstdc++ entirely.
- Uses analog stick to simulate tilt and gyro hw. By default, tilt uses
the right analog stick while gyro uses the left. The analog stick can be
swapped using a core option provided and with separate sensitivity level
for both sensors. WIP and will be fine tuned later (Kirby was fun to
play at least)
- Minor retro_run() cleanup and some minor stuff i forgot.
- Updates descriptors for 4-player SGB
- Remove alternate gamepad layouts for GBA
- Prevent crash when SGB border option executes at startup when GB is not
initialized yet
- Update input turbo function for 4-player support
- Minor cleanups (texts, style nits, etc)...
Check for __LIBRETRO__ before including getopt.h in ConfigManager.h,
because windows does not come with this header or function, and libretro
does not need it.
Allow serial emulation without having the need to run link-related
communication stuff (NO_LINK define). Some games need this e.g. RC Pro-AM
racing. Dummy funcs/vars are added as placeholders.
Currently work-in-progress and might need to disable some more NO_LINK
sections.
Remove esc to quit key bind #298.
Remove ctrl+x (cmd+x on mac) to quit key bind #334.
Remove FilterEvent app method, it is no longer being used anyway as key binds
work correctly.