[NCSF] Removed the Cnv_Scale function as it seemed to cause sounds to be too loud in some cases.
[NCSF] Removed the Cnv_Scale function as it seemed to cause sounds to be too loud in some cases.

--- a/src/in_ncsf/SSEQPlayer/Channel.cpp
+++ b/src/in_ncsf/SSEQPlayer/Channel.cpp
@@ -71,8 +71,8 @@
 void Channel::UpdateVol(const Track &trk)
 {
 	int finalVol = trk.ply->masterVol;
-	finalVol += Cnv_Scale(trk.vol);
-	finalVol += Cnv_Scale(trk.expr);
+	finalVol += Cnv_Sust(trk.vol);
+	finalVol += Cnv_Sust(trk.expr);
 	this->extAmpl = finalVol;
 }
 

--- a/src/in_ncsf/SSEQPlayer/Track.cpp
+++ b/src/in_ncsf/SSEQPlayer/Track.cpp
@@ -187,7 +187,7 @@
 	chn->prio = this->prio;
 	chn->key = key;
 	chn->orgKey = bIsPCM ? noteDef->noteNumber : 69;
-	chn->velocity = Cnv_Scale(vel);
+	chn->velocity = Cnv_Sust(vel);
 	chn->pan = static_cast<int>(noteDef->pan) - 64;
 	chn->modDelayCnt = 0;
 	chn->modCounter = 0;
@@ -229,7 +229,7 @@
 	chn->flags.reset();
 	chn->prio = this->prio;
 	chn->key = key;
-	chn->velocity = Cnv_Scale(vel);
+	chn->velocity = Cnv_Sust(vel);
 	chn->modDelayCnt = 0;
 	chn->modCounter = 0;
 

--- a/src/in_ncsf/SSEQPlayer/common.h
+++ b/src/in_ncsf/SSEQPlayer/common.h
@@ -159,33 +159,6 @@
 		return ((fall << 1) + 1) & 0xFFFF;
 	else
 		return (0x1E00 / (0x7E - fall)) & 0xFFFF;
-}
-
-// This function actually doesn't come from FSS, I got the lookup table from the Nintendo DS SDK.
-inline int Cnv_Scale(int scale)
-{
-	static const int16_t lut[] =
-	{
-		-32768, -421, -361, -325, -300, -281, -265, -252,
-		-240, -230, -221, -212, -205, -198, -192, -186,
-		-180, -175, -170, -165, -161, -156, -152, -148,
-		-145, -141, -138, -134, -131, -128, -125, -122,
-		-120, -117, -114, -112, -110, -107, -105, -103,
-		-100, -98, -96, -94, -92, -90, -88, -86,
-		-85, -83, -81, -79, -78, -76, -74, -73,
-		-71, -70, -68, -67, -65, -64, -62, -61,
-		-60, -58, -57, -56, -54, -53, -52, -51,
-		-49, -48, -47, -46, -45, -43, -42, -41,
-		-40, -39, -38, -37, -36, -35, -34, -33,
-		-32, -31, -30, -29, -28, -27, -26, -25,
-		-24, -23, -23, -22, -21, -20, -19, -18,
-		-17, -17, -16, -15, -14, -13, -12, -12,
-		-11, -10, -9, -9, -8, -7, -6, -6,
-		-5, -4, -3, -3, -2, -1, -1, 0
-	};
-	if (scale & 0x80)
-		scale = 0x7F;
-	return lut[scale];
 }
 
 inline int Cnv_Sust(int sust)