Merge pull request #1333 from brooksytech/dev

Adding new ES features
This commit is contained in:
Brooksytech 2023-04-25 11:27:50 -07:00 committed by GitHub
commit 597e17e3c7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 253 additions and 42 deletions

View file

@ -24,10 +24,25 @@ fi
#Prep PCSX2.ini for audio
sed -i '/^BackendName =/c\BackendName =' /storage/.config/aethersx2/inis/PCSX2.ini
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
#All..
unset EMUPERF
fi
#Emulation Station Features
GAME=$(echo "${1}"| sed "s#^/.*/##")
ASPECT=$(get_setting aspect_ratio ps2 "${GAME}")
FPS=$(get_setting show_fps ps2 "${GAME}")
RATE=$(get_setting ee_cycle_rate ps2 "${GAME}")
SKIP=$(get_setting ee_cycle_skip ps2 "${GAME}")
GRENDERER=$(get_setting graphics_backend ps2 "${GAME}")
VSYNC=$(get_setting vsync ps2 "${GAME}")
@ -49,16 +64,20 @@ sed -i '/^BackendName =/c\BackendName =' /storage/.config/aethersx2/inis/PCSX2.i
#Graphics Backend
if [ "$GRENDERER" = "0" ]
then
sed -i '/^Renderer =/c\Renderer = 12' /storage/.config/aethersx2/inis/PCSX2.ini
sed -i '/^Renderer =/c\Renderer = -1' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$GRENDERER" = "1" ]
then
sed -i '/^Renderer =/c\Renderer = 14' /storage/.config/aethersx2/inis/PCSX2.ini
sed -i '/^Renderer =/c\Renderer = 12' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$GRENDERER" = "2" ]
then
sed -i '/^Renderer =/c\Renderer = 13' /storage/.config/aethersx2/inis/PCSX2.ini
sed -i '/^Renderer =/c\Renderer = 14' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$GRENDERER" = "3" ]
then
sed -i '/^Renderer =/c\Renderer = 13' /storage/.config/aethersx2/inis/PCSX2.ini
fi
#Show FPS
if [ "$FPS" = "false" ]
@ -70,15 +89,55 @@ sed -i '/^BackendName =/c\BackendName =' /storage/.config/aethersx2/inis/PCSX2.i
sed -i '/^OsdShowFPS =/c\OsdShowFPS = true' /storage/.config/aethersx2/inis/PCSX2.ini
fi
#Vsync
if [ "$VSYNC" = "0" ]
then
sed -i '/^VsyncEnable =/c\VsyncEnable = 0' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$VSYNC" = "1" ]
then
sed -i '/^VsyncEnable =/c\VsyncEnable = 1' /storage/.config/aethersx2/inis/PCSX2.ini
fi
#EE Cycle Rate
sed -i '/^EECycleRate =/c\EECycleRate = 0' /storage/.config/aethersx2/inis/PCSX2.ini
if [ "$RATE" = "0" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = -3' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "1" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = -2' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "2" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = -1' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "3" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = 0' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "4" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = 1' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "5" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = 2' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$RATE" = "6" ]
then
sed -i '/^EECycleRate =/c\EECycleRate = 3' /storage/.config/aethersx2/inis/PCSX2.ini
fi
#EE Cycle Skip
sed -i '/^EECycleSkip =/c\EECycleSkip = 0' /storage/.config/aethersx2/inis/PCSX2.ini
if [ "$SKIP" = "0" ]
then
sed -i '/^EECycleSkip =/c\EECycleSkip = 0' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$SKIP" = "1" ]
then
sed -i '/^EECycleSkip =/c\EECycleSkip = 1' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$SKIP" = "2" ]
then
sed -i '/^EECycleSkip =/c\EECycleSkip = 2' /storage/.config/aethersx2/inis/PCSX2.ini
fi
if [ "$SKIP" = "3" ]
then
sed -i '/^EECycleSkip =/c\EECycleSkip = 3' /storage/.config/aethersx2/inis/PCSX2.ini
fi
#Set OpenGL 3.3 on panfrost
export PAN_MESA_DEBUG=gl3,gofaster
@ -88,5 +147,5 @@ sed -i '/^BackendName =/c\BackendName =' /storage/.config/aethersx2/inis/PCSX2.i
#Run Aethersx2 emulator
set_audio pulseaudio
/usr/bin/@APPIMAGE@ -fullscreen "${1}"
${EMUPERF} /usr/bin/@APPIMAGE@ -fullscreen "${1}"
set_audio alsa

View file

@ -24,6 +24,19 @@ fi
rm -rf /storage/.config/dolphin-emu/StateSaves
ln -sf /storage/roms/savestates/gamecube /storage/.config/dolphin-emu/StateSaves
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
#Emulation Station Features
GAME=$(echo "${1}"| sed "s#^/.*/##")
AA=$(get_setting anti_aliasing gamecube "${GAME}")
@ -32,6 +45,7 @@ ln -sf /storage/roms/savestates/gamecube /storage/.config/dolphin-emu/StateSaves
IRES=$(get_setting internal_resolution gamecube "${GAME}")
FPS=$(get_setting show_fps gamecube "${GAME}")
CON=$(get_setting gamecube_controller_profile gamecube "${GAME}")
VSYNC=$(get_setting vsync gamecube "${GAME}")
#Anti-Aliasing
if [ "$AA" = "0" ]
@ -137,9 +151,19 @@ ln -sf /storage/roms/savestates/gamecube /storage/.config/dolphin-emu/StateSaves
cp -r /storage/.config/dolphin-emu/Custom_GCPadNew.ini /storage/.config/dolphin-emu/GCPadNew.ini
fi
#VSYNC
if [ "$VSYNC" = "0" ]
then
sed -i '/VSync =/c\VSync = False' /storage/.config/dolphin-emu/GFX.ini
fi
if [ "$VSYNC" = "1" ]
then
sed -i '/VSync =/c\VSync = True' /storage/.config/dolphin-emu/GFX.ini
fi
#Link .config/dolphin-emu to .local
rm -rf /storage/.local/share/dolphin-emu
ln -sf /storage/.config/dolphin-emu /storage/.local/share/dolphin-emu
#Run Dolphin emulator
/usr/bin/dolphin-emu-nogui -p @DOLPHIN_PLATFORM@ -a HLE -e "${1}"
${EMUPERF} /usr/bin/dolphin-emu-nogui -p @DOLPHIN_PLATFORM@ -a HLE -e "${1}"

View file

@ -24,6 +24,19 @@ if [ ! -d "/storage/roms/savestates/wii/" ]; then
mkdir -p "/storage/roms/savestates/wii/"
fi
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
rm -rf /storage/.config/dolphin-emu/StateSaves
ln -sf /storage/roms/savestates/wii /storage/.config/dolphin-emu/StateSaves
@ -35,6 +48,7 @@ ln -sf /storage/roms/savestates/wii /storage/.config/dolphin-emu/StateSaves
IRES=$(get_setting internal_resolution wii "${GAME}")
FPS=$(get_setting show_fps wii "${GAME}")
CON=$(get_setting wii_controller_profile wii "${GAME}")
VSYNC=$(get_setting vsync wii "${GAME}")
#Anti-Aliasing
if [ "$AA" = "0" ]
@ -148,9 +162,19 @@ ln -sf /storage/roms/savestates/wii /storage/.config/dolphin-emu/StateSaves
cp -r /storage/.config/dolphin-emu/Custom_WiimoteNew.ini /storage/.config/dolphin-emu/WiimoteNew.ini
fi
#VSYNC
if [ "$VSYNC" = "0" ]
then
sed -i '/VSync =/c\VSync = False' /storage/.config/dolphin-emu/GFX.ini
fi
if [ "$VSYNC" = "1" ]
then
sed -i '/VSync =/c\VSync = True' /storage/.config/dolphin-emu/GFX.ini
fi
#Link .config/dolphin-emu to .local
rm -rf /storage/.local/share/dolphin-emu
ln -sf /storage/.config/dolphin-emu /storage/.local/share/dolphin-emu
#Run Dolphin emulator
/usr/bin/dolphin-emu-nogui -p @DOLPHIN_PLATFORM@ -a HLE -e "${1}"
${EMUPERF} /usr/bin/dolphin-emu-nogui -p @DOLPHIN_PLATFORM@ -a HLE -e "${1}"

View file

@ -24,6 +24,19 @@ ln -sf /storage/roms/savestates/nds /storage/.config/drastic/savestates
rm -rf /storage/.config/drastic/backup
ln -sf /storage/roms/nds /storage/.config/drastic/backup
# Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
cd /storage/.config/drastic/
export SDL_VIDEO_GL_DRIVER=./libs/libGL.so.1
@ -32,4 +45,4 @@ export LIBGL_ES=2
export LIBGL_GL=21
export LIBGL_FB=2
./drastic "$1"
${EMUPERF} ./drastic "$1"

View file

@ -5,22 +5,37 @@
. /etc/profile
#Copy config folder to .config/duckstation
if [ ! -d "/storage/.config/duckstation" ]; then
mkdir -p "/storage/.config/duckstation"
cp -r "/usr/config/duckstation" "/storage/.config/"
fi
#Link savestates to roms/savestates
if [ ! -d "/storage/roms/savestates/psx" ]; then
mkdir -p "/storage/roms/savestates/psx"
fi
if [ -d "/storage/.config/duckstation/savestates" ]; then
rm -rf "/storage/.config/duckstation/savestates"
fi
ln -sfv "/storage/roms/savestates/psx" "/storage/.config/duckstation/savestates"
#Copy gamecontroller db file from the device.
cp -rf /storage/.config/SDL-GameControllerDB/gamecontrollerdb.txt /storage/.config/duckstation/database/gamecontrollerdb.txt
cp -rf /storage/.config/SDL-GameControllerDB/gamecontrollerdb.txt /storage/.config/duckstation/resources/gamecontrollerdb.txt
duckstation-nogui -fullscreen -settings "/storage/.config/duckstation/settings.ini" -- "${1}" > /dev/null 2>&1
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
#Run Duckstation
${EMUPERF} duckstation-nogui -fullscreen -settings "/storage/.config/duckstation/settings.ini" -- "${1}" > /dev/null 2>&1

View file

@ -16,10 +16,23 @@ if [ ! -d "/storage/roms/bios/dc" ]; then
mkdir -p "/storage/roms/bios/dc"
fi
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
#Link .config/flycast to .local
rm -rf "/storage/.local/share/flycast"
ln -sf "/storage/.config/flycast" "/storage/.local/share/flycast"
ln -sf "/storage/roms/bios/dc" "/storage/.local/share/flycast"
#Run flycast emulator
/usr/bin/flycast "${1}"
${EMUPERF} /usr/bin/flycast "${1}"

View file

@ -42,6 +42,19 @@ mkdir -p $TMP
cp $M64PCONF $TMP
SET_PARAMS="--set Core[SharedDataPath]=$TMP --set Video-Rice[ResolutionWidth]=$SCREENWIDTH"
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
#Aspect Ratio
if [ "${ASPECT}" = "fullscreen" ]; then
# TODO: Set aspect ratio to fullscreen
@ -97,15 +110,15 @@ echo ${SET_PARAMS}
case $1 in
"m64p_gliden64")
/usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-GLideN64 $SET_PARAMS "$2"
${EMUPERF} /usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-GLideN64 $SET_PARAMS "$2"
;;
"m64p_gl64mk2")
/usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-glide64mk2 $SET_PARAMS "$2"
${EMUPERF} /usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-glide64mk2 $SET_PARAMS "$2"
;;
"m64p_rice")
/usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-rice $SET_PARAMS "$2"
${EMUPERF} /usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-rice $SET_PARAMS "$2"
;;
*)
/usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-rice $SET_PARAMS "$2"
${EMUPERF} /usr/local/bin/mupen64plus --configdir $TMP --gfx mupen64plus-video-rice $SET_PARAMS "$2"
;;
esac

View file

@ -90,7 +90,7 @@ pre_make_target() {
makeinstall_target() {
mkdir -p ${INSTALL}/usr/bin
cp ${PKG_DIR}/sources/start_ppsspp.sh ${INSTALL}/usr/bin
cp ${PKG_DIR}/scripts/start_ppsspp.sh ${INSTALL}/usr/bin
cp PPSSPPSDL ${INSTALL}/usr/bin/ppsspp
chmod 0755 ${INSTALL}/usr/bin/*
ln -sf /storage/.config/ppsspp/assets ${INSTALL}/usr/bin/assets

View file

@ -0,0 +1,22 @@
#!/bin/sh
# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2021-present - Fewtarius
. /etc/profile
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
ARG=${1//[\\]/}
export SDL_AUDIODRIVER=alsa
${EMUPERF} ppsspp "${ARG}"

View file

@ -1,9 +0,0 @@
#!/bin/sh
# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2021-present - Fewtarius
. /etc/profile
ARG=${1//[\\]/}
export SDL_AUDIODRIVER=alsa
ppsspp "${ARG}"

View file

@ -70,5 +70,18 @@ then
cp -f ${SOURCE_DIR}/.config "${CONFIG_DIR}/${GAME}.config"
fi
#Set the cores to use
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
if [ "${CORES}" = "little" ]
then
EMUPERF="${SLOW_CORES}"
elif [ "${CORES}" = "big" ]
then
EMUPERF="${FAST_CORES}"
else
### All..
unset EMUPERF
fi
echo "Command: yabasanshiro -r 2 -i "${1}" ${BIOS}" >/var/log/exec.log 2>&1
yabasanshiro -r 2 -i "${1}" ${BIOS} >>/var/log/exec.log 2>&1 ||:
${EMUPERF} yabasanshiro -r 2 -i "${1}" ${BIOS} >>/var/log/exec.log 2>&1 ||:

View file

@ -80,6 +80,10 @@
<choice name="gc gamepad" value="gcpad"/>
<choice name="custom" value="custom"/>
</feature>
<feature name="vsync">
<choice name="off" value="0"/>
<choice name="on" value="1"/>
</feature>
</features>
</core>
<core name="dolphin-sa-wii">
@ -119,6 +123,10 @@
<choice name="Classic Controller" value="classic"/>
<choice name="custom" value="custom"/>
</feature>
<feature name="vsync">
<choice name="off" value="0"/>
<choice name="on" value="1"/>
</feature>
</features>
</core>
</cores>
@ -178,6 +186,10 @@
<choice name="Classic Controller" value="classic"/>
<choice name="custom" value="custom"/>
</feature>
<feature name="vsync">
<choice name="off" value="0"/>
<choice name="on" value="1"/>
</feature>
</features>
</emulator>
<emulator name="yuzu">
@ -298,19 +310,31 @@
<choice name="16/9" value="1"/>
<choice name="stretch" value="2"/>
</feature>
<feature name="ee cycle rate">
<choice name="50% speed" value="0"/>
<choice name="60% speed" value="1"/>
<choice name="75% speed" value="2"/>
<choice name="100% speed (normal)" value="3"/>
<choice name="130% speed" value="4"/>
<choice name="180% speed" value="5"/>
<choice name="300% speed" value="6"/>
</feature>
<feature name="ee cycle skip">
<choice name="normal" value="0"/>
<choice name="mild underclock" value="1"/>
<choice name="moderate underclock" value="2"/>
<choice name="maximum underclock" value="3"/>
</feature>
<feature name="graphics backend">
<choice name="opengl" value="0"/>
<choice name="vulkan" value="1"/>
<choice name="software" value="2"/>
<choice name="automatic" value="0"/>
<choice name="opengl" value="1"/>
<choice name="vulkan" value="2"/>
<choice name="software" value="3"/>
</feature>
<feature name="show fps">
<choice name="yes" value="true"/>
<choice name="no" value="false"/>
</feature>
<feature name="vsync">
<choice name="off" value="0"/>
<choice name="on" value="1"/>
</feature>
</features>
</core>
</cores>