* Refactors setsettings to greatly improve performance.
* Fixes the memory and gpu governor function for RK3399 and S922X. * Automatically set the aspect ratio in EmulationStation.
This commit is contained in:
parent
a1aa9dc844
commit
170791a9c7
8 changed files with 720 additions and 678 deletions
|
@ -173,6 +173,7 @@ system.battery.warning=1
|
|||
system.cpugovernor=schedutil
|
||||
system.hostname=@DEVICENAME@
|
||||
system.language=en_US
|
||||
system.loglevel=none
|
||||
system.overclock=off
|
||||
system.power.audio=1
|
||||
system.power.cpu=1
|
||||
|
|
|
@ -61,7 +61,7 @@ set_dmc_gov() {
|
|||
then
|
||||
for governor in $1 dmc_$1 simple_$1
|
||||
do
|
||||
echo $1 >${DMC_FREQ}/governor 2>/dev/null || echo dmc_$1 >${DMC_FREQ}/governor 2>/dev/null
|
||||
echo ${governor} >${DMC_FREQ}/governor 2>/dev/null
|
||||
if [ "$?" = 0 ]
|
||||
then
|
||||
return
|
||||
|
@ -75,7 +75,7 @@ set_gpu_gov() {
|
|||
then
|
||||
for governor in $1 dmc_$1 simple_$1
|
||||
do
|
||||
echo $1 >${GPU_FREQ}/governor 2>/dev/null
|
||||
echo ${governor} >${GPU_FREQ}/governor 2>/dev/null
|
||||
if [ "$?" = 0 ]
|
||||
then
|
||||
return
|
||||
|
|
|
@ -54,8 +54,21 @@ case ${ASPECT} in
|
|||
1.76|0.56)
|
||||
ASPECT="16:9"
|
||||
;;
|
||||
1.6|0.62)
|
||||
ASPECT="16:10"
|
||||
;;
|
||||
esac
|
||||
|
||||
### Set the aspect ratio in ES.
|
||||
ES_CONFIG="/storage/.config/emulationstation/es_settings.cfg"
|
||||
ES_ASPECT="${ASPECT/:/-}"
|
||||
if [ "$(grep subset.aspect-ratio ${ES_CONFIG})" ]
|
||||
then
|
||||
sed -i 's|<string name="subset.aspect-ratio".*$|<string name="subset.aspect-ratio" value="'${ES_ASPECT}'"/>|g' ${ES_CONFIG}
|
||||
else
|
||||
sed -i '/<\/config>/i \\t<string name="subset.aspect-ratio" value="'${ES_ASPECT}'"/>' ${ES_CONFIG}
|
||||
fi
|
||||
|
||||
if [ -f "/storage/.config/emulationstation/resources/logo.png" ]
|
||||
then
|
||||
rm -f /storage/.config/emulationstation/resources/logo.png ||:
|
||||
|
|
|
@ -22,7 +22,7 @@ LOGSDIR="/var/log"
|
|||
LOGFILE="exec.log"
|
||||
TBASH="/usr/bin/bash"
|
||||
RATMPCONF="/storage/.config/retroarch/retroarch.cfg"
|
||||
RAAPPENDCONF="/tmp/raappend.cfg"
|
||||
RAAPPENDCONF="/tmp/.retroarch.cfg"
|
||||
NETPLAY="No"
|
||||
SHADERTMP="/tmp/shader"
|
||||
OUTPUT_LOG="${LOGSDIR}/${LOGFILE}"
|
||||
|
@ -48,7 +48,6 @@ ROMNAME="$1"
|
|||
BASEROMNAME=${ROMNAME##*/}
|
||||
GAMEFOLDER="${ROMNAME//${BASEROMNAME}}"
|
||||
|
||||
|
||||
### Determine if we're running a Libretro core and append the libretro suffix
|
||||
if [[ $EMULATOR = "retroarch" ]]; then
|
||||
EMU="${CORE}_libretro"
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -428,10 +428,10 @@ set_consolefont() {
|
|||
progress "Set console font"
|
||||
if [ -e /dev/fb0 ]; then
|
||||
hres="$(fbset 2>/dev/null | awk '/geometry/ { print $2 }')"
|
||||
if [ "${hres}" -gt "0" ] && [ "${hres}" -lt "640" ]
|
||||
if [ "${hres}" -gt "0" ] && [ "${hres}" -le "640" ]
|
||||
then
|
||||
setfont -C /dev/console ter-v12n.psf
|
||||
elif [ "${hres}" -ge "640" ] && [ "${hres}" -lt "720" ]
|
||||
elif [ "${hres}" -ge "641" ] && [ "${hres}" -lt "720" ]
|
||||
then
|
||||
setfont -C /dev/console ter-v14n.psf
|
||||
elif [ "${hres}" -ge "720" ] && [ "${hres}" -lt "1080" ]
|
||||
|
|
|
@ -55,8 +55,21 @@ then
|
|||
1.76|0.56)
|
||||
ASPECT="16:9"
|
||||
;;
|
||||
1.6|0.62)
|
||||
ASPECT="16:10"
|
||||
;;
|
||||
esac
|
||||
|
||||
### Set the aspect ratio in ES.
|
||||
ES_CONFIG="/storage/.config/emulationstation/es_settings.cfg"
|
||||
ES_ASPECT="${ASPECT/:/-}"
|
||||
if [ "$(grep subset.aspect-ratio ${ES_CONFIG})" ]
|
||||
then
|
||||
sed -i 's|<string name="subset.aspect-ratio".*$|<string name="subset.aspect-ratio" value="'${ES_ASPECT}'"/>|g' ${ES_CONFIG}
|
||||
else
|
||||
sed -i '/<\/config>/i \\t<string name="subset.aspect-ratio" value="'${ES_ASPECT}'"/>' ${ES_CONFIG}
|
||||
fi
|
||||
|
||||
if [ -f "/storage/.config/emulationstation/resources/logo.png" ]
|
||||
then
|
||||
rm -f /storage/.config/emulationstation/resources/logo.png ||:
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
# Copyright (C) 2020-present Fewtarius
|
||||
|
||||
PKG_NAME="emulationstation"
|
||||
PKG_VERSION="7723ff4"
|
||||
PKG_VERSION="6dafa36"
|
||||
PKG_GIT_CLONE_BRANCH="main"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
|
|
Loading…
Reference in a new issue