public Intervention\Image\Image pixel(mixed $color, integer $x, integer $y)
Draw a single pixel in given color on x, y position.
The color of the pixel. Pass a color in one of the different color formats.
x-coordinate of the pixel.
y-coordinate of the pixel.
Instance of Intervention\Image\Image
// create empty canvas with background color
$img = Image::canvas(100, 100, '#ddd');
// draw a blue pixel
$img->pixel('#0000ff', 32, 32);
// draw a red pixel
$img->pixel('#ff0000', 64, 64);
2023-09-08 更新 本文链接:https://upwqy.com/index.php/wiki/info/911.html