I have the following arrays:
cMaxSampleDuration = 420;
MyDoubleArray: array[0..5, 0..cMaxSampleDuration -1] of Double;
MyIntegerArray: array[0..5, 0..cMaxSampleDuration -1] of Integer;
with the following function i convert the float number to integers:
for Channel := 0 to 6 -1 do
for Samples := 0 to cMaxSampleDuration -1 do
MyIntegerArray[Channel, Samples] := Round(Frac(MyDoubleArray[Channel, Samples]) * 200000);
Comment: Since it's a wave i care only for the fractional part of the float not the integer.
Now, i want to normalize the array so the scale up every channel to be in the same range.
(Like normilizing a waveform, in this case 6 channels/waves)