cvs: phpdoc-es /reference/image/functions imagecolorat.xml

From: Date: Sat, 06 Aug 2005 12:19:44 +0000
Subject: cvs: phpdoc-es /reference/image/functions imagecolorat.xml
Groups: php.doc.es 
Request: Send a blank email to doc-es+get-1222@lists.php.net to get a copy of this message
javi Sat Aug 6 08:19:44 2005 EDT Modified files: /phpdoc-es/reference/image/functions imagecolorat.xml Log: - Añadido EN-Revision - Redactada de nuevo casi por completo http://cvs.php.net/diff.php/phpdoc-es/reference/image/functions/imagecolorat.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc-es/reference/image/functions/imagecolorat.xml diff -u phpdoc-es/reference/image/functions/imagecolorat.xml:1.1 phpdoc-es/reference/image/functions/imagecolorat.xml:1.2 --- phpdoc-es/reference/image/functions/imagecolorat.xml:1.1 Sun Apr 14 20:14:51 2002 +++ phpdoc-es/reference/image/functions/imagecolorat.xml Sat Aug 6 08:19:43 2005 @@ -1,25 +1,48 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- splitted from ./es/functions/image.xml, last change in rev 1.1 --> -<!-- last change to 'imagecolorat' in en/ tree in rev 1.36 --> +<!-- $Revision: 1.2 $ --> +<!-- EN-Revision: 1.4 Maintainer: javi Status: ready --> +<!-- splitted from ./en/functions/image.xml, last change in rev 1.36 --> <refentry id="function.imagecolorat"> <refnamediv> - <refname>ImageColorAt</refname> + <refname>imagecolorat</refname> <refpurpose>Obtiende el &iacute;ndice del color de un pixel</refpurpose> </refnamediv> <refsect1> <title>Descripci&oacute;n</title> <methodsynopsis> <type>int</type><methodname>imagecolorat</methodname> - <methodparam><type>int</type><parameter>im</parameter></methodparam> + <methodparam><type>resource</type><parameter>im</parameter></methodparam> <methodparam><type>int</type><parameter>x</parameter></methodparam> <methodparam><type>int</type><parameter>y</parameter></methodparam> </methodsynopsis> <para> Devuelve el &iacute;ndice del color del pixel especificado - en la posici&oacute;n de la imagen.</para> + en la posici&oacute;n de la imagen. + </para> <para> - Vea tambi&eacute;n <function>imagecolorset</function> y - <function>imagecolorsforindex</function>.</para> + Si PHP est&aacute; compilado con soporte para la librer&iacute; GD 2.0 o superior + y la imagen es una imagen con color real, la funci&oacute;n devuelve el valor + RGB del pixel como un n&uacute;mero entero. Se pueden usar m&aacute;scaras l&oacute;gicas + de bits para acceder a los valores de los distintos componentes del color: + <example> + <title>Accediendo a los componentes del color RGB</title> + <programlisting role="php"> +<![CDATA[ +<?php +$im = ImageCreateFromPng("rockym.png"); +$rgb = ImageColorAt($im, 100, 100); +$r = ($rgb >> 16) & 0xFF; +$g = ($rgb >> 8) & 0xFF; +$b = $rgb & 0xFF; +?> +]]> + </programlisting> + </example> + </para> + <para> + Vea tambi&eacute;n <function>imagecolorset</function> y + <function>imagecolorsforindex</function>. + </para> </refsect1> </refentry>

« previous php.doc.es (#1222) next »