]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - misc/tools/fft-normalmap-to-heightmap-soft.sh
demotc-race-record-extractor.sh: remove useless rc case (gametype name is always...
[xonotic/xonotic.git] / misc / tools / fft-normalmap-to-heightmap-soft.sh
index 9f861fc35dc0c98e5a4fbcbf65279dfd97c7d3d8..708d44484b14b6c14a049f705d0da46a7d082e4c 100755 (executable)
@@ -39,6 +39,6 @@ extraoffset=`echo "($realmedian + $ofs / $realscale)" | bc -l`
 #
 # we need p_d^-1(p_t(x)) = 1 - (128 + 127 * x) / 255
 #
-extraoffset=`echo "(127.0 / 255.0) * (1 - $extraoffset)" | bc -l`
+extraoffset="match8 "`echo "128 + 127 * $extraoffset" | bc -l`
 
 echo " dpoffsetmapping - $extrascale $extraoffset"