]> Pileus Git - ~andy/gtk/blob - docs/reference/gdk-pixbuf/gdk-pixbuf-csource.xml
Documentation fixes.
[~andy/gtk] / docs / reference / gdk-pixbuf / gdk-pixbuf-csource.xml
1 <refentry id="gdk-pixbuf-csource">
2
3 <refmeta>
4 <refentrytitle>gdk-pixbuf-csource</refentrytitle>
5 <manvolnum>1</manvolnum>
6 </refmeta>
7
8 <refnamediv>
9 <refname>gdk-pixbuf-csource</refname>
10 <refpurpose>C code generation utility for GdkPixbuf images</refpurpose>
11 </refnamediv>
12
13 <refsynopsisdiv>
14 <cmdsynopsis>
15 <command>gdk-pixbuf-csource</command>
16 <arg choice="opt">options</arg>
17 <arg choice="opt">image</arg>
18 </cmdsynopsis>
19 <cmdsynopsis>
20 <command>gdk-pixbuf-csource</command>
21 <arg choice="opt">options</arg>
22 <arg choice="plain">--build-list</arg>
23 <arg rep="repeat">
24   <arg>name</arg>
25   <arg>image</arg>
26 </arg>
27 </cmdsynopsis>
28 </refsynopsisdiv>
29
30 <refsect1><title>Description</title>
31 <para>
32 <command>gdk-pixbuf-csource</command> is a small utility that generates C code
33 containing images, useful for compiling images directly into programs.
34 </para>
35 </refsect1>
36
37 <refsect1><title>Invocation</title>
38 <para>
39 <command>gdk-pixbuf-csource</command> either takes as input one image file name
40 to generate code for, or, using the <option>--build-list</option> option, a 
41 list of (<replaceable>name</replaceable>, <replaceable>image</replaceable>)
42 pairs to generate code for a list of images into named variables.
43 </para>
44 <refsect2><title>Options</title>
45 <variablelist>
46
47 <varlistentry>
48 <term><option>--stream</option></term>
49 <listitem><para>
50 Generate pixbuf data stream (a single string containing a serialized
51 <structname>GdkPixdata</structname> structure in network byte order).
52 </para></listitem>
53 </varlistentry>
54
55 <varlistentry>
56 <term><option>--struct</option></term>
57 <listitem><para>
58 Generate GdkPixdata structure (needs the <structname>GdkPixdata</structname>
59 structure definition from <filename>gdk-pixdata.h</filename>).
60 </para></listitem>
61 </varlistentry>
62
63 <varlistentry>
64 <term><option>--macros</option></term>
65 <listitem><para>
66 Generate *_ROWSTRIDE, *_WIDTH, *_HEIGHT, *_BYTES_PER_PIXEL and
67 *_RLE_PIXEL_DATA or *_PIXEL_DATA macro definitions for the image.
68 </para></listitem>
69 </varlistentry>
70
71 <varlistentry>
72 <term><option>--rle</option></term>
73 <listitem><para>
74 Enables run-length encoding for the generated pixel data (default).
75 </para></listitem>
76 </varlistentry>
77
78 <varlistentry>
79 <term><option>--raw</option></term>
80 <listitem><para>
81 Disables run-length encoding for the generated pixel data.
82 </para></listitem>
83 </varlistentry>
84
85 <varlistentry>
86 <term><option>--extern</option></term>
87 <listitem><para>
88 Generate extern symbols.
89 </para></listitem>
90 </varlistentry>
91
92 <varlistentry>
93 <term><option>--static</option></term>
94 <listitem><para>
95 Generate static symbols (default).
96 </para></listitem>
97 </varlistentry>
98
99 <varlistentry>
100 <term><option>--decoder</option></term>
101 <listitem><para>
102 Provide a *_RUN_LENGTH_DECODE(image_buf, rle_data, size, bpp) macro definition
103 to decode run-length encoded image data.
104 </para></listitem>
105 </varlistentry>
106
107 <varlistentry>
108 <term><option>--name=identifier</option></term>
109 <listitem><para>
110 Specifies the identifier name (prefix) for the generated variables or
111 macros (useful only if <option>--build-list</option> was not specified).
112 </para></listitem>
113 </varlistentry>
114
115 <varlistentry>
116 <term><option>--build-list</option></term>
117 <listitem><para>
118 Enables (<replaceable>name</replaceable>, <replaceable>image</replaceable>)
119 pair parsing mode.
120 </para></listitem>
121 </varlistentry>
122
123 <varlistentry>
124 <term><option>-h</option>, <option>--help</option></term>
125 <listitem><para>
126 Print brief help and exit.
127 </para></listitem>
128 </varlistentry>
129
130 <varlistentry>
131 <term><option>-v</option>, <option>--version</option></term>
132 <listitem><para>
133 Print version and exit.
134 </para></listitem>
135 </varlistentry>
136
137 <varlistentry>
138 <term><option>--g-fatal-warnings</option></term>
139 <listitem><para>
140 Make warnings fatal (causes the program to abort).
141 </para></listitem>
142 </varlistentry>
143
144 </variablelist>
145 </refsect2>
146 </refsect1>
147
148 <refsect1><title>See also</title>
149 <para>
150 The <structname>GdkPixbuf</structname> documentation, shipped with the 
151 Gtk+ distribution, available from <ulink url="http://www.gtk.org">www.gtk.org</ulink>.
152 </para>
153 </refsect1>
154
155 <refsect1><title>Bugs</title>
156 <para>
157 The runlength encoder gets out of sync with the pixel boundaries, since
158 it includes the rowstride padding in the encoded stream. Furthermore, it
159 generates pixbufs with suboptimal rowstride in some cases.
160 </para>
161 </refsect1>
162
163 <refsect1><title>Author</title>
164 <para>
165 <command>gdk-pixbuf-csource</command> was written by Tim Janik
166 <email>timj@gtk.org</email>. 
167 </para>
168 <para>
169 This manual page was provided by Tim Janik <email>timj@gtk.org</email>. 
170 </para>
171 </refsect1>
172 </refentry>
173