<?php imageistruecolor(GdImage $image): bool
<?php $color = imagecolorat($image->getCore(), $x, $y); if ( ! imageistruecolor($image->getCore())) { $color = imagecolorsforindex($image->getCore(), $color); $color['alpha'] = round(1 - $color['alpha'] / 127, 2); }
<?php public static function castGd($gd, array $a, Stub $stub, bool $isNested) { $a['size'] = imagesx($gd).'x'.imagesy($gd); $a['trueColor'] = imageistruecolor($gd); return $a; }