php-doc-en/reference/pdf/functions/pdf-open-memory-image.xml
2003-02-12 18:05:23 +00:00

63 lines
1.8 KiB
XML

<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.3 $ -->
<!-- splitted from ./en/functions/pdf.xml, last change in rev 1.48 -->
<refentry id="function.pdf-open-memory-image">
<refnamediv>
<refname>pdf_open_memory_image</refname>
<refpurpose>Opens an image created with PHP's image functions</refpurpose>
</refnamediv>
<refsect1>
<title>Description</title>
<methodsynopsis>
<type>int</type><methodname>pdf_open_memory_image</methodname>
<methodparam><type>int</type><parameter>pdf_object</parameter></methodparam>
<methodparam><type>int</type><parameter>image</parameter></methodparam>
</methodsynopsis>
<para>
The <function>pdf_open_memory_image</function> function takes
an image created with the PHP's image functions and makes it available
for the pdf object. The function returns a pdf
image identifier.
<example>
<title>Including a memory image</title>
<programlisting>
<![CDATA[
<?php
$im = ImageCreate(100, 100);
$col = ImageColorAllocate($im, 80, 45, 190);
ImageFill($im, 10, 10, $col);
$pim = pdf_open_memory_image($pdf, $im);
ImageDestroy($im);
pdf_place_image($pdf, $pim, 100, 100, 1);
pdf_close_image($pdf, $pim);
?>
]]>
</programlisting>
</example></para>
<para>
See also <function>pdf_close_image</function>,
<function>pdf_place_image</function>.</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->