private Color ProcessColor(Color inputColor) { if (EnableGamma) { var gammaCorrector = new GammaCorrector(); return(gammaCorrector.Encode(inputColor)); } return(inputColor); }
//----------------------------------------------------------------------------------------------------- //Гамма-коррекция матриц public static RealMatrix[] GetGammaCorrectedMatrices( double[] coefficients, double[] powers, params RealMatrix[] matrices ) { RealMatrix[] newMatrices = new RealMatrix[matrices.Length]; for (int index = 0; index < matrices.Length; index++) { RealMatrix matrix = matrices[index]; RealMatrix newMatrix = GammaCorrector.GetGammaCorrectedMatrix(matrix, coefficients, powers); newMatrices[index] = newMatrix; } return(newMatrices); }