Fix Duckstation sa and add additional ES features
This commit is contained in:
parent
a46140d5dc
commit
d42ff69c82
3 changed files with 91 additions and 2 deletions
|
@ -70,9 +70,23 @@ makeinstall_target() {
|
|||
mkdir -p ${INSTALL}/usr/config/duckstation
|
||||
cp -rf ${PKG_BUILD}/.${TARGET_NAME}/bin/* ${INSTALL}/usr/config/duckstation
|
||||
cp -rf ${PKG_DIR}/config/${DEVICE}/* ${INSTALL}/usr/config/duckstation
|
||||
cp -rf ${PKG_BUILD}/data/* ${INSTALL}/usr/config/duckstation
|
||||
|
||||
rm -rf ${INSTALL}/usr/config/duckstation/duckstation-nogui
|
||||
rm -rf ${INSTALL}/usr/config/duckstation/common-tests
|
||||
|
||||
chmod +x ${INSTALL}/usr/bin/start_duckstation.sh
|
||||
}
|
||||
|
||||
post_install() {
|
||||
case ${DEVICE} in
|
||||
RK356*)
|
||||
RESOURCE_FOLDER="database"
|
||||
;;
|
||||
*)
|
||||
RESOURCE_FOLDER="resources"
|
||||
;;
|
||||
esac
|
||||
sed -e "s/@RESOURCE_FOLDER@/${RESOURCE_FOLDER}/g" \
|
||||
-i ${INSTALL}/usr/bin/start_duckstation.sh
|
||||
}
|
||||
|
|
|
@ -22,8 +22,7 @@ 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
|
||||
cp -rf /storage/.config/SDL-GameControllerDB/gamecontrollerdb.txt /storage/.config/duckstation/@RESOURCE_FOLDER@/gamecontrollerdb.txt
|
||||
|
||||
#Set the cores to use
|
||||
CORES=$(get_setting "cores" "${PLATFORM}" "${ROMNAME##*/}")
|
||||
|
@ -40,7 +39,53 @@ fi
|
|||
|
||||
#Emulation Station Features
|
||||
GAME=$(echo "${1}"| sed "s#^/.*/##")
|
||||
ASPECT=$(get_setting aspect_ratio psx "${GAME}")
|
||||
FPS=$(get_setting show_fps psx "${GAME}")
|
||||
IRES=$(get_setting internal_resolution psx "${GAME}")
|
||||
RENDERER=$(get_setting graphics_backend psx "${GAME}")
|
||||
VSYNC=$(get_setting vsync psx "${GAME}")
|
||||
|
||||
#Aspect Ratio
|
||||
if [ "$ASPECT" = "0" ]
|
||||
then
|
||||
sed -i '/^AspectRatio/c\AspectRatio = 4:3' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$ASPECT" = "1" ]
|
||||
then
|
||||
sed -i '/^AspectRatio/c\AspectRatio = 16:9' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
|
||||
#Show FPS
|
||||
if [ "$FPS" = "false" ]
|
||||
then
|
||||
sed -i '/^ShowFPS/c\ShowFPS = false' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$FPS" = "true" ]
|
||||
then
|
||||
sed -i '/^ShowFPS/c\ShowFPS = true' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
|
||||
#Internal Resolution
|
||||
if [ "$IRES" = "1" ]
|
||||
then
|
||||
sed -i '/^ResolutionScale =/c\ResolutionScale = 1' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$IRES" = "2" ]
|
||||
then
|
||||
sed -i '/^ResolutionScale =/c\ResolutionScale = 2' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$IRES" = "3" ]
|
||||
then
|
||||
sed -i '/^ResolutionScale =/c\ResolutionScale = 3' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$IRES" = "4" ]
|
||||
then
|
||||
sed -i '/^ResolutionScale =/c\ResolutionScale = 4' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$IRES" = "5" ]
|
||||
then
|
||||
sed -i '/^ResolutionScale =/c\ResolutionScale = 5' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
|
||||
#Video Backend
|
||||
if [ "$RENDERER" = "opengl" ]
|
||||
|
@ -56,5 +101,16 @@ fi
|
|||
sed -i '/^Renderer =/c\Renderer = Software' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
|
||||
#VSYNC
|
||||
if [ "$VSYNC" = "off" ]
|
||||
then
|
||||
sed -i '/^VSync =/c\VSync = false' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
if [ "$VSYNC" = "on" ]
|
||||
then
|
||||
sed -i '/^VSync =/c\VSync = true' /storage/.config/duckstation/settings.ini
|
||||
fi
|
||||
|
||||
|
||||
#Run Duckstation
|
||||
${EMUPERF} duckstation-nogui -fullscreen -settings "/storage/.config/duckstation/settings.ini" -- "${1}" > /dev/null 2>&1
|
||||
|
|
|
@ -123,11 +123,30 @@
|
|||
<cores>
|
||||
<core name="duckstation-sa">
|
||||
<features>
|
||||
<feature name="aspect ratio">
|
||||
<choice name="4/3" value="0"/>
|
||||
<choice name="16/9" value="1"/>
|
||||
</feature>
|
||||
<feature name="graphics backend">
|
||||
<choice name="opengl" value="opengl"/>
|
||||
<choice name="vulkan" value="vulkan"/>
|
||||
<choice name="software" value="software"/>
|
||||
</feature>
|
||||
<feature name="internal resolution">
|
||||
<choice name="1x" value="1"/>
|
||||
<choice name="2x" value="2"/>
|
||||
<choice name="3x" value="3"/>
|
||||
<choice name="4x" value="4"/>
|
||||
<choice name="5x" value="5"/>
|
||||
</feature>
|
||||
<feature name="show fps">
|
||||
<choice name="yes" value="true"/>
|
||||
<choice name="no" value="false"/>
|
||||
</feature>
|
||||
<feature name="vsync">
|
||||
<choice name="off" value="off"/>
|
||||
<choice name="on" value="on"/>
|
||||
</feature>
|
||||
</features>
|
||||
</core>
|
||||
</cores>
|
||||
|
|
Loading…
Reference in a new issue