예제 #1
0
        /// <summary>
        /// Returns the correction mask.
        /// </summary>
        /// <param name="a">Factor [-1, 1]</param>
        /// <param name="length">Length</param>
        /// <returns>Matrix</returns>
        public static float[,] SAUCE(float a, int length)
        {
            float[,] table = new float[length, length];
            float w, v;
            int   x, y;

            for (x = 0; x < length; x++)
            {
                w = x / (float)length;

                for (y = 0; y < length; y++)
                {
                    v = y / (float)length;

                    table[x, y] = Intensity.SAUCE(w, v, a);
                }
            }

            return(table);
        }