Sitemap
Kontakt
Links
+++ erd.trabant +++

+++ erd.trabant +++

blablabla

blablabla

Wasserzeichen / Watermark

function watermark($srcfilename, $newname, $watermark, $quality) {
    $imageInfo = getimagesize($srcfilename);
    $width = $imageInfo[0];
    $height = $imageInfo[1];
    $logoinfo = getimagesize($watermark);
    $logowidth = $logoinfo[0];
    $logoheight = $logoinfo[1];
    $horizextra =$width - $logowidth;
    $vertextra =$height - $logoheight;
    $horizmargin =  round($horizextra / 2);
    $vertmargin =  round($vertextra / 2);
    $photoImage = ImageCreateFromJPEG($srcfilename);
    ImageAlphaBlending($photoImage, true);
    $logoImage = ImageCreateFromPNG($watermark);
    //this sucks: fuck off....: $logoImage=imagerotate($logoImage, 45,0);
    $logoW = ImageSX($logoImage);
    $logoH = ImageSY($logoImage);
    ImageCopy($photoImage, $logoImage, $horizmargin, $vertmargin, 0, 0, $logoW, $logoH);
    //ImageJPEG($photoImage); // output to browser
    ImageJPEG($photoImage,$newname, $quality);
    ImageDestroy($photoImage);
    ImageDestroy($logoImage);
    //watermark ("in.jpg","out.jpg","wmark.png",80);

}

>>PopUP / Drucken / Print<<
blablabla