change the fallback for an unknown make_colors value to match the default
authorTony Cook <tony@develop-help.com>
Mon, 14 Mar 2011 08:30:53 +0000 (19:30 +1100)
committerTony Cook <tony@develop-help.com>
Mon, 14 Mar 2011 08:30:53 +0000 (19:30 +1100)
Imager.xs

index e9a7952475c6c553ed64e76b6c58cad9c80d0c0d..6fef57e54788702ab01c97eb6317b7e8610c6f1f 100644 (file)
--- a/Imager.xs
+++ b/Imager.xs
@@ -645,7 +645,7 @@ ip_handle_quant_opts(pTHX_ i_quantize *quant, HV *hv)
   sv = hv_fetch(hv, "make_colors", 11, 0);
   if (sv && *sv && (str = SvPV(*sv, len))) {
     quant->make_colors = 
-      lookup_name(make_color_names, sizeof(make_color_names)/sizeof(*make_color_names), str, mc_addi);
+      lookup_name(make_color_names, sizeof(make_color_names)/sizeof(*make_color_names), str, mc_median_cut);
   }
   sv = hv_fetch(hv, "colors", 6, 0);
   if (sv && *sv && SvROK(*sv) && SvTYPE(SvRV(*sv)) == SVt_PVAV) {