<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
<!ENTITY version SYSTEM "version.xml">
]>
<refentry id="cutter-Assertions-with-gdk-pixbuf-support">
<refmeta>
<refentrytitle role="top_of_page" id="cutter-Assertions-with-gdk-pixbuf-support.top_of_page">Assertions with gdk-pixbuf support</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>CUTTER Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>Assertions with gdk-pixbuf support</refname>
<refpurpose>Checks that your program works as you
expect with gdk-pixbuf support.</refpurpose>
</refnamediv>

<refsect1 id="cutter-Assertions-with-gdk-pixbuf-support.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_return" colwidth="150px"/>
<colspec colname="functions_name"/>
<tbody>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="gdkcut-pixbuf-assert-equal">gdkcut_pixbuf_assert_equal</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>


<refsect1 id="cutter-Assertions-with-gdk-pixbuf-support.description" role="desc">
<title role="desc.title">Description</title>

</refsect1>
<refsect1 id="cutter-Assertions-with-gdk-pixbuf-support.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="gdkcut-pixbuf-assert-equal" role="function" condition="since:1.0.5">
<title>gdkcut_pixbuf_assert_equal&#160;()</title>
<indexterm zone="gdkcut-pixbuf-assert-equal" role="1.0.5"><primary>gdkcut_pixbuf_assert_equal</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
gdkcut_pixbuf_assert_equal (<parameter>const <link linkend="GdkPixbuf"><type>GdkPixbuf</type></link> *expected</parameter>,
                            <parameter>const <link linkend="GdkPixbuf"><type>GdkPixbuf</type></link> *actual</parameter>,
                            <parameter><link linkend="guint"><type>guint</type></link> threshold</parameter>,
                            <parameter>...</parameter>);</programlisting>
<para>Passes if <parameter>expected</parameter>
 == <parameter>actual</parameter>
. If difference of each
corresponding pixel value is within threshold, <parameter>expected</parameter>

and <parameter>actual</parameter>
 are treated as equal image.</para>
<para>If threshold is 3, pixel value of <parameter>expected</parameter>
 at (1, 1) is
127 and pixel value of <parameter>actual</parameter>
 at (1, 1) is 131, <parameter>actual</parameter>

doesn't equals to <parameter>expected</parameter>
. If pixel value of <parameter>actual</parameter>
 at
(1, 1) is 130, <parameter>actual</parameter>
 may equal to <parameter>expected</parameter>
. (All other
corresponding pixel values are needed to fill this
condition.)</para>
<refsect3 id="gdkcut-pixbuf-assert-equal.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>expected</para></entry>
<entry role="parameter_description"><para>an expected <link linkend="GdkPixbuf"><type>GdkPixbuf</type></link>.</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>actual</para></entry>
<entry role="parameter_description"><para>an actual <link linkend="GdkPixbuf"><type>GdkPixbuf</type></link>.</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>threshold</para></entry>
<entry role="parameter_description"><para>an threshold used for detecting pixel difference.</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>...</para></entry>
<entry role="parameter_description"><para>optional message. See <link linkend="cut-message"><function>cut_message()</function></link> for details.</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.0.5">1.0.5</link></para></refsect2>

</refsect1>
<refsect1 id="cutter-Assertions-with-gdk-pixbuf-support.other_details" role="details">
<title role="details.title">Types and Values</title>

</refsect1>

</refentry>
