diff options
author | neonloop | 2021-10-20 14:46:17 +0000 |
---|---|---|
committer | neonloop | 2021-10-20 14:46:17 +0000 |
commit | 7c003401f4f1e5463f20af1dc63b25ad8a15e3c1 (patch) | |
tree | 2483c34fe9a7f585ea2065566071469a7963fe78 | |
parent | 0a40303ac6cea506ff678986af5c43d3f689352b (diff) | |
download | picoarch-7c003401f4f1e5463f20af1dc63b25ad8a15e3c1.tar.gz picoarch-7c003401f4f1e5463f20af1dc63b25ad8a15e3c1.tar.bz2 picoarch-7c003401f4f1e5463f20af1dc63b25ad8a15e3c1.zip |
Adds QuickNES core
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile | 10 | ||||
-rw-r--r-- | overrides.c | 2 | ||||
-rw-r--r-- | overrides/quicknes.h | 87 | ||||
-rw-r--r-- | patches/quicknes/1000-trimui-build.patch | 25 |
5 files changed, 123 insertions, 2 deletions
@@ -13,5 +13,6 @@ picoarch /mame2000 /mame2003_plus /pcsx_rearmed +/quicknes /snes9x2002 /snes9x2005 @@ -20,7 +20,7 @@ LDFLAGS = -lc -ldl -lgcc -lm -lSDL -lasound -lpng -lz -Wl,--gc-sections -flto # EXTRA_CORES += fbalpha2012 # EXTRA_CORES += mame2003_plus -CORES = beetle-pce-fast fceumm gambatte gpsp mame2000 pcsx_rearmed snes9x2002 snes9x2005 $(EXTRA_CORES) +CORES = beetle-pce-fast fceumm gambatte gpsp mame2000 pcsx_rearmed quicknes snes9x2002 snes9x2005 $(EXTRA_CORES) beetle-pce-fast_REPO = https://github.com/libretro/beetle-pce-fast-libretro beetle-pce-fast_CORE = mednafen_pce_fast_libretro.so @@ -38,6 +38,8 @@ mame2003_plus_REPO = https://github.com/libretro/mame2003-plus-libretro pcsx_rearmed_MAKEFILE = Makefile.libretro +quicknes_REPO = https://github.com/libretro/QuickNES_Core + ifeq ($(platform), trimui) OBJS += plat_trimui.o CFLAGS += -mcpu=arm926ej-s -mtune=arm926ej-s -fno-PIC -DCONTENT_DIR='"/mnt/SDCARD/Roms"' @@ -147,7 +149,7 @@ fbalpha2012_PAK_NAME = Arcade (FBA) fceumm_ROM_DIR = FC fceumm_TYPES = fds,nes,unf,unif -fceumm_PAK_NAME = Nintendo +fceumm_PAK_NAME = Nintendo (fceumm) gambatte_ROM_DIR = GB gambatte_TYPES = gb,gbc,dmg,zip @@ -180,6 +182,10 @@ needs-swap endef +quicknes_ROM_DIR = FC +quicknes_TYPES = nes +quicknes_PAK_NAME = Nintendo + snes9x2002_ROM_DIR = SFC snes9x2002_TYPES = smc,fig,sfc,gd3,gd7,dx2,bsx,swc,zip snes9x2002_PAK_NAME = Super Nintendo diff --git a/overrides.c b/overrides.c index fdb010e..2cc9488 100644 --- a/overrides.c +++ b/overrides.c @@ -5,6 +5,7 @@ #include "overrides/gpsp.h" #include "overrides/mame2000.h" #include "overrides/pcsx_rearmed.h" +#include "overrides/quicknes.h" #include "overrides/snes9x2002.h" #include "overrides/snes9x2005.h" #include "util.h" @@ -16,6 +17,7 @@ static const struct core_override overrides[] = { gpsp_overrides, mame2000_overrides, pcsx_rearmed_overrides, + quicknes_overrides, snes9x2002_overrides, snes9x2005_overrides, }; diff --git a/overrides/quicknes.h b/overrides/quicknes.h new file mode 100644 index 0000000..f132951 --- /dev/null +++ b/overrides/quicknes.h @@ -0,0 +1,87 @@ +#include "overrides.h" + +static const struct core_override_option quicknes_core_option_overrides[] = { + { + .key = "quicknes_use_overscan_h", + .desc = "Horiz. Overscan", + .info = "When disabled, crop out (horizontally) the potentially random glitchy video output that would have been hidden by the TV screen bezel.", + }, + { + .key = "quicknes_use_overscan_v", + .desc = "Vert. Overscan", + .info = "When disabled, crop out (vertically) the potentially random glitchy video output that would have been hidden by the TV screen bezel.", + }, + { + .key = "quicknes_palette", + .desc = "Palette", + .options = { + { "default", "Default" }, + { "asqrealc", "ASQ's Real" }, + { "nintendo-vc", "Nintendo VC" }, + { "rgb", "Nintendo RGB PPU" }, + { "yuv-v3", "FBX's YUV-V3" }, + { "unsaturated-final", "FBX's Unsaturated" }, + { "sony-cxa2025as-us", "Sony CXA2025AS US" }, + { "pal", "PAL" }, + { "bmf-final2", "BMF's Final 2" }, + { "bmf-final3", "BMF's Final 3" }, + { "smooth-fbx", "FBX's Smooth" }, + { "composite-direct-fbx", "FBX's Compos. Direct" }, + { "pvm-style-d93-fbx", "FBX's PVM Style D93" }, + { "ntsc-hardware-fbx", "FBX's NTSC Hardware" }, + { "nes-classic-fbx-fs", "FBX's NES-Classic FS" }, + { "nescap", "RGBSource's NESCAP" }, + { "wavebeam", "nakedarthur's Wavebeam" }, + { NULL, NULL}, + }, + }, + { + .key = "quicknes_no_sprite_limit", + .info = "Removes the 8-sprite-per-scanline hardware limit. Reduces flickering at the risk of visual glitches.", + }, + { + .key = "quicknes_audio_eq", + .desc = "Audio EQ", + }, + { + .key = "quicknes_audio_nonlinear", + .info = "'Non-Linear' simulates the NES APU. 'Linear' is less accurate but faster. 'Stereo Panning' adds depth with panning techniques and reverb.", + }, + { + .key = "quicknes_turbo_pulse_width", + .desc = "Turbo (in frames)", + .info = "Specifies on / off frame count when turbo buttons are held." + }, + { + .key = "quicknes_up_down_allowed", + .desc = "Allow Opp. Input", + .info = "Enabling allows pressing both left and right (or up and down) directions at the same time. May cause glitches." + }, + { + .key = "quicknes_aspect_ratio_par", + .blocked = true + }, + { NULL } +}; + +me_bind_action quicknes_ctrl_actions[] = +{ + { "UP ", 1 << RETRO_DEVICE_ID_JOYPAD_UP}, + { "DOWN ", 1 << RETRO_DEVICE_ID_JOYPAD_DOWN }, + { "LEFT ", 1 << RETRO_DEVICE_ID_JOYPAD_LEFT }, + { "RIGHT ", 1 << RETRO_DEVICE_ID_JOYPAD_RIGHT }, + { "A ", 1 << RETRO_DEVICE_ID_JOYPAD_A }, + { "B ", 1 << RETRO_DEVICE_ID_JOYPAD_B }, + { "A TURBO ", 1 << RETRO_DEVICE_ID_JOYPAD_X }, + { "B TURBO ", 1 << RETRO_DEVICE_ID_JOYPAD_Y }, + { "SELECT ", 1 << RETRO_DEVICE_ID_JOYPAD_START }, + { "START ", 1 << RETRO_DEVICE_ID_JOYPAD_SELECT }, + { NULL, 0 } +}; + +#define quicknes_overrides { \ + .core_name = "quicknes", \ + .actions = quicknes_ctrl_actions, \ + .action_size = array_size(quicknes_ctrl_actions), \ + .options = quicknes_core_option_overrides \ +} diff --git a/patches/quicknes/1000-trimui-build.patch b/patches/quicknes/1000-trimui-build.patch new file mode 100644 index 0000000..8cc40f9 --- /dev/null +++ b/patches/quicknes/1000-trimui-build.patch @@ -0,0 +1,25 @@ +diff --git a/Makefile b/Makefile +index 2405fd3..a075991 100644 +--- a/Makefile ++++ b/Makefile +@@ -383,6 +383,20 @@ else ifeq ($(platform), miyoo) + PLATFORM_DEFINES += -O3 -fomit-frame-pointer -march=armv5te -mtune=arm926ej-s -ffast-math + CXXFLAGS += -fno-rtti -fno-exceptions + ++# TRIMUI ++else ifeq ($(platform), trimui) ++ TARGET := $(TARGET_NAME)_libretro.so ++ CC = $(CROSS_COMPILE)gcc ++ CXX = $(CROSS_COMPILE)g++ ++ AR = $(CROSS_COMPILE)ar ++ SHARED := -shared -Wl,--version-script=link.T -Wl,-no-undefined ++ PLATFORM_DEFINES := -DNO_UNALIGNED_ACCESS ++ PLATFORM_DEFINES += -Ofast -fomit-frame-pointer -march=armv5te -mtune=arm926ej-s -ffast-math -fno-PIC -flto ++ CXXFLAGS += -fno-rtti -fno-exceptions ++ ifeq (,$(DEBUG)) ++ LDFLAGS += -s ++ endif ++ + # Windows MSVC 2017 all architectures + else ifneq (,$(findstring windows_msvc2017,$(platform))) + |