@@ -0,0 +1,1489 @@
+package colormaps.impl;%0A%0Aimport static java.lang.Math.PI;%0Aimport static java.lang.Math.atan2;%0Aimport static java.lang.Math.hypot;%0A%0Aimport java.awt.Color;%0Aimport java.util.Collections;%0Aimport java.util.List;%0A%0Aimport org.slf4j.Logger;%0Aimport org.slf4j.LoggerFactory;%0A%0Aimport colormaps.AbstractColormap2D;%0Aimport colormaps.ColorSpace;%0Aimport colorspaces.HSL;%0A%0Apublic class Ramirez2012 extends AbstractColormap2D %7B%0A%0A%09Logger _log = LoggerFactory.getLogger(getClass());%0A%09%0A%09@Override%0A%09public Color getColor(double x, double y) %7B%0A%09%09// normalize to -1..1%0A%09%09double nx = (float) (x * 2 - 1);%0A%09%09double ny = (float) (y * 2 - 1);%0A%09%09double dist = hypot(nx, ny) / hypot(1, 1);%0A%09%09double ang = (atan2(nx, ny)+PI)/(PI*2);%0A%09%09// HSL matches as good or bad as HSI - need HSV?%0A%09%09//%0A%09%09//double%5B%5D rgb = HSI.hsi2rgb(new double%5B%5D %7Bang * PI * 2, dist, (float)(1f-dist/2f)%7D);%0A%09%09//return new Color((float)rgb%5B0%5D, (float)rgb%5B1%5D, (float)rgb%5B2%5D);%0A%09%09return HSL.HSLtoRGB((float)ang, (float)dist, (float)(1f-dist/2f));%0A%09%7D%0A%0A%09@Override%0A%09public String getName() %7B%0A%09%09return %22Ramirez2012%22;%0A%09%7D%0A%0A%09@Override%0A%09public String getDescription() %7B%0A%09%09return %22HSL-based map with white center and maximal saturation.%22;%0A%09%7D%0A%0A%09@Override%0A%09public ColorSpace getColorSpace() %7B%0A%09%09return ColorSpace.HSV;%0A%09%7D%0A%0A%09@Override%0A%09public List%3CString%3E getReferences() %7B%0A%09%09return Collections.singletonList(%22ramirez2012self%22);%0A%09%7D%0A%0A%09@Override%0A%09protected Color getColor(float x, float y) %7B%0A%09%09throw new IllegalStateException(%22this method shuld not be called%22);%0A%09%7D%0A%0A%7D%0A

add Ramirez map