[FEATURE] Option to convert a raster to grayscale with choice of desaturation mode (lightness, luminosity, average) (fix #5837)