array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'es', ), 'this' => array ( 0 => 'function.png2wbmp.php', 1 => 'png2wbmp', ), 'up' => array ( 0 => 'ref.image.php', 1 => 'Funciones de GD e Imágenes', ), 'prev' => array ( 0 => 'function.jpeg2wbmp.php', 1 => 'jpeg2wbmp', ), 'next' => array ( 0 => 'book.gmagick.php', 1 => 'Gmagick', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'es', 'path' => 'reference/image/functions/png2wbmp.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 4 >= 4.0.5, PHP 5, PHP 7)
png2wbmp — Convertir un archivo de imagen PNG a un archivo de imagen WBMP
$pngname
,$wbmpname
,$dest_height
,$dest_width
,$threshold
Convierte un archivo PNG a un archivo WBMP.
pngname
Ruta del archivo PNG.
wbmpname
Ruta del archivo WBMP de destino.
dest_height
Alto de la imagen de destino.
dest_width
Ancho de la imagen de destino.
threshold
Valor de umbral, entre 0 y 8 (inclusive).
Ejemplo #1 Ejmplo de png2wbmp()
<?php
// Ruta al png objetivo
$ruta = './prueba.png';
// Obtener las dimensiones de la imagen
$imagen = getimagesize($ruta);
// Convertir la imagen
png2wbmp($ruta, './prueba.wbmp', $imagen[1], $imagen[0], 7);
?>