Ver Mensaje Individual
  #1 (permalink)  
Antiguo 16/07/2011, 20:31
kozenko
 
Fecha de Ingreso: octubre-2010
Mensajes: 83
Antigüedad: 13 años, 6 meses
Puntos: 1
Transparencia color en imagettftext

Hola!
Estoy tratando de hacer un watermark. Tengo esta funcion:

Código PHP:
<?php
function watermarkImage ($SourceFile$WaterMarkText$WaterMarkText2$DestinationFile) { 
   list(
$width$height) = getimagesize($SourceFile);
   
$image_p imagecreatetruecolor($width$height);
   
$image imagecreatefrompng($SourceFile);
   
imagecopyresampled($image_p$image0000$width$height$width$height); 
   
$black imagecolorallocate($image_p000);
   
$font 'OctemberScript.ttf';
   
$font_size 30
   
imagettftext($image_p$font_size3020250$black$font$WaterMarkText);
   
imagettftext($image_p$font_size3020300$black$font$WaterMarkText2);
   
imagepng ($image_p$DestinationFile9); 
   
imagedestroy($image); 
   
imagedestroy($image_p); 
}
?>
Queria saber como hacer que el color del watermark, en este caso $black sea semi transparente.

Gracias de antemano
Salu2
Koz