code: private static double hueToRGB(final double m1, final double m2, double h)
      {
          // see http://www.w3.org/TR/css3-color/
          //
          // HOW TO RETURN hue.to.rgb(m1, m2, h):
          // IF h<0: PUT h+1 IN h
          // IF h>1: PUT h-1 IN h
          // IF h*6<1: RETURN m1+(m2-m1)*h*6
          // IF h*2<1: RETURN m2
          // IF h*3<2: RETURN m1+(m2-m1)*(2/3-h)*6
          // RETURN m1
  
          if (h < 0)
          {
              h++;
          }
          if (h > 1)
          {
              h--;
          }
          if ((h * 6) < 1)
          {
              return m1 + ((m2 - m1) * h * 6);
          }
          if ((h * 2) < 1)
          {
              return m2;
          }
          if ((h * 3) < 2)
          {
              return m1 + ((m2 - m1) * ((2.0 / 3) - h) * 6);
          }
          return m1;
      }
docs: Used by {@link #fromNormalizedHSL(double, double, double)}
  
  @param m1
  @param m2
  @param h
  @return