How does one go about converting an image to black and white in PHP?
Not just turning it into greyscale but every pixel made black or white?
$rgb = imagecolorat($original, $x, $y); $r = ($rgb >> 16) & 0xFF; $g = ($rgb >> 8 ) & 0xFF; $b = $rgb & 0xFF; $gray = $r + $g + $b/3; if ($gray >0xFF) {$grey = 0xFFFFFF;} else { $grey=0x000000;}