Debian Codegraph @

opcodes/imagesave.xml

raw symbols SCIP
1
2 <refentry id="imagesave">
3 <indexterm id="IndexImagesave"><primary>imagesave</primary></indexterm>
4 <refentryinfo><title>Image Processing Opcodes</title></refentryinfo>
5 <refmeta>
6 <refentrytitle>imagesave</refentrytitle>
7 </refmeta>
8
9 <refnamediv>
10 <refname>imagesave</refname>
11 <refpurpose>
12 Save a previously created image.
13 </refpurpose>
14 </refnamediv>
15
16 <refsect1>
17 <title>Description</title>
18 <para>Plugin opcode in image. This opcode is part of the plugin repository and has to be installed separately.
19 The plugin repository can be found here: <ulink url="https://github.com/csound/plugins"><citetitle>https://github.com/csound/plugins</citetitle></ulink></para>
20 <para>
21 Save a previously created image. An empty image can be created with <link linkend="imagecreate"><citetitle>imagecreate</citetitle></link> and its pixel RGB values can be set with <link linkend="imagesetpixel"><citetitle>imagesetpixel</citetitle></link>. The image will be saved in PNG format.
22 </para>
23 </refsect1>
24
25 <refsect1>
26 <title>Syntax</title>
27 <synopsis><command>imagesave</command> iimagenum, filename</synopsis>
28 </refsect1>
29
30 <refsect1>
31 <title>Initialization</title>
32 <para>
33 <emphasis>iimagenum</emphasis> -- the reference of the image to be save. It should be a value returned by <link linkend="imagecreate"><citetitle>imagecreate</citetitle></link>.
34 </para>
35 <para>
36 <emphasis>filename</emphasis> -- The filename to use to save the image.
37 </para>
38 </refsect1>
39
40 <refsect1>
41 <title>Examples</title>
42 <para>
43 Here is an example of the imagesave opcode. It uses the file <ulink url="examples/imageopcodes.csd"><citetitle>imageopcodes.csd</citetitle></ulink> and <ulink url="examples/imageOpcode01.png"><citetitle>imageOpcode01.png</citetitle></ulink>.
44 <example>
45 <title>Example of the imagesave opcode.</title>
46 <xi:include href="examples-xml/imageopcodes.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
47 </example>
48 <para>
49 This is what the saved image <citetitle>imageOUT.png</citetitle> looks like:
50 </para>
51 <imageobject>
52 <imagedata fileref="images/imageOUTsmall.png" format="PNG"/>
53 </imageobject>
54 </para>
55 </refsect1>
56
57 <refsect1>
58 <title>See also</title>
59 <para><link linkend="ImageopcodesTop"><citetitle>Image processing opcodes</citetitle></link></para>
60 </refsect1>
61
62 <refsect1>
63 <title>Credits</title>
64 <para>
65 <simplelist>
66 <member>Author: Cesare Marilungo</member>
67 </simplelist>
68 </para>
69 <para>New in version 5.08</para>
70 </refsect1>
71 </refentry>