We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If I connect two images, I get an error message: notice: Implicit conversion from float 50.800000000000004 to int loses precision.
$imageWatermark = new SimpleImage(); $imageWatermark ->fromFile(WWW_ROOT . 'img' . DS . 'logo-watermark.png') ->resize($image->getWidth() / 5); $image->overlay($imageWatermark, 'bottom right', .6, -25, -25);
This function does it: $image->overlay(...);
Thank you
The text was updated successfully, but these errors were encountered:
If I modify the code as follows, it no longer returns the error.
protected static function imageCopyMergeAlpha($dstIm, $srcIm, $dstX, $dstY, $srcX, $srcY, $srcW, $srcH, $pct) { // Are we merging with transparency? if($pct < 100) { // Disable alpha blending and "colorize" the image using a transparent color imagealphablending($srcIm, false); imagefilter($srcIm, IMG_FILTER_COLORIZE, 0, 0, 0, round(127 * ((100 - $pct) / 100))); } imagecopy($dstIm, $srcIm, (int) $dstX, (int) $dstY, (int) $srcX, (int) $srcY, (int) $srcW, (int) $srcH); return true; }
Original line:
imagefilter($srcIm, IMG_FILTER_COLORIZE, 0, 0, 0, 127 * ((100 - $pct) / 100));
Sorry, something went wrong.
Fixed in #310.
No branches or pull requests
If I connect two images, I get an error message: notice: Implicit conversion from float 50.800000000000004 to int loses precision.
This function does it: $image->overlay(...);
Thank you
The text was updated successfully, but these errors were encountered: