$image->interlace((int) (bool) $params); break; case 'fill': if (!$params) { break; } $check_size_allowed($params); if (!preg_match('/^[0-9]+x[0-9]+x[0-9a-f]{6}$/i', $params)) { if (!Settings::isProductionState()) { exit('Error processing params for action "fill". Example: 32x32xff00cc'); } die; } $check_size_allowed($params); list($x, $y, $c) = explode('x', $params); $image->apply(); $ih = $image->getHandler(); $c = imageColorAllocate($ih, hexdec($c[0] . $c[1]), hexdec($c[2] . $c[3]), hexdec($c[4] . $c[5])); imageFilledRectangle($ih, $x, $y, imagesX($ih), imagesY($ih), $c); unset($ih); break; case 'rectangle': if (!$params) { break; } $check_size_allowed($params); if (!preg_match('/^[0-9]+x[0-9]+x[0-9]+x[0-9]+x[0-9a-f]{6}$/i', $params)) { if (!Settings::isProductionState()) { exit('Error processing params for action "rectangle". Example: 32x32x64x64xff00cc'); } die;