spec: Explicitly document components of on image data

Since we're just passing it ultimately to gdk_pixbuf_new_from_data in
the server, we really should be documenting the restrictions here, such
as bits_per_sample always being 8.

https://bugzilla.gnome.org/show_bug.cgi?id=647672
This commit is contained in:
Colin Walters 2011-04-13 10:47:41 -04:00 committed by Matthias Clasen
parent d12145208a
commit 52cb20bb53
1 changed files with 12 additions and 3 deletions

View File

@ -380,9 +380,18 @@
<sect2 id="icons-and-images-formats" xreflabel="Icons and Images Formats">
<title>Formats</title>
<para>
The "image-data" and "icon_data" hints should be a raw image data structure
of signature (iiibiiay) which describes the width, height, rowstride, has
alpha, bits per sample, channels and image data respectively.
The "image-data" and "icon_data" hints should be a DBus structure
of signature (iiibiiay). The components of this structure are as follows:
<orderedlist>
<listitem><para>width (i): Width of image in pixels</para></listitem>
<listitem><para>height (i): Height of image in pixels</para></listitem>
<listitem><para>rowstride (i): Distance in bytes between row starts</para></listitem>
<listitem><para>has_alpha (b): Whether the image has an alpha channel</para></listitem>
<listitem><para>bits_per_sample (i): Must always be 8</para></listitem>
<listitem><para>channels (i): If has_alpha is TRUE, must be 4, otherwise 3</para></listitem>
<listitem><para>data (ay): The image data, in RGB byte order</para></listitem>
</orderedlist>
This image format is derived from <ulink url="http://developer.gnome.org/gdk-pixbuf/stable/">gdk-pixbuf</ulink>.
</para>
<para>
The "app_icon" parameter and "image-path" hint should be either an URI