File tree Expand file tree Collapse file tree 1 file changed +0
-19
lines changed
Expand file tree Collapse file tree 1 file changed +0
-19
lines changed Original file line number Diff line number Diff line change @@ -77,30 +77,11 @@ killall audioserver
7777
7878ui_print " "
7979ui_print " Patching existing audio_effects files..."
80- osp_detect () {
81- case " $1 " in
82- * .conf)
83- SPACES=$( sed -n " /^output_session_processing {/,/^}/ {/^ *music {/p}" $1 | sed -r " s/( *).*/\1/" )
84- EFFECTS=$( sed -n " /^output_session_processing {/,/^}/ {/^$SPACES \music {/,/^$SPACES }/p}" $1 | grep -E " ^$SPACES +[A-Za-z]+" | sed -r " s/( *.*) .*/\1/g" )
85- for EFFECT in ${EFFECTS} ; do
86- SPACES=$( sed -n " /^effects {/,/^}/ {/^ *$EFFECT {/p}" $1 | sed -r " s/( *).*/\1/" )
87- [ " $EFFECT " != " atmos" ] && sed -i " /^effects {/,/^}/ {/^$SPACES$EFFECT {/,/^$SPACES }/ s/^/#/g}" $1
88- done
89- ;;
90- * .xml)
91- EFFECTS=$( sed -n " /^ *<postprocess>$/,/^ *<\/postprocess>$/ {/^ *<stream type=\" music\" >$/,/^ *<\/stream>$/ {/<stream type=\" music\" >/d; /<\/stream>/d; s/<apply effect=\" //g; s/\" \/>//g; p}}" $1 )
92- for EFFECT in ${EFFECTS} ; do
93- [ " $EFFECT " != " atmos" ] && sed -ri " s/^( *)<apply effect=\" $EFFECT \" \/>/\1<\!--<apply effect=\" $EFFECT \" \/>-->/" $1
94- done
95- ;;
96- esac
97- }
9880AUDIO_EFFECTS_FILES=" $( find /system /vendor -type f -name " *audio_effects*.conf" -o -name " *audio_effects*.xml" ) "
9981for ORIGINAL_FILE in $AUDIO_EFFECTS_FILES ; do
10082 ui_print " Patching $ORIGINAL_FILE "
10183 FILE=" $MODPATH $( echo " $ORIGINAL_FILE " | sed " s|^/vendor|/system/vendor|g" ) "
10284 cp_ch " $ORIGDIR$ORIGINAL_FILE " " $FILE "
103- osp_detect " $FILE "
10485 case " $FILE " in
10586 * .conf)
10687 sed -i " /v4a_standard_fx {/,/}/d" " $FILE "
You can’t perform that action at this time.
0 commit comments