<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>libgutenprint API Reference: color</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.4 --> <div id="top"> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">libgutenprint API Reference <span id="projectnumber">5.2.7</span></div> </td> </tr> </tbody> </table> </div> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#nested-classes">Data Structures</a> | <a href="#typedef-members">Typedefs</a> | <a href="#func-members">Functions</a> </div> <div class="headertitle"> <div class="title">color</div> </div> </div> <div class="contents"> <p>The color data type is responsible for providing colour conversion features. <a href="#details">More...</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="nested-classes"></a> Data Structures</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structstp__colorfuncs__t.html">stp_colorfuncs_t</a></td></tr> <tr><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structstp__color.html">stp_color</a></td></tr> <tr><td colspan="2"><h2><a name="typedef-members"></a> Typedefs</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="structstp__color.html">stp_color</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#gad1408f9835b72f266ec7c7e1e1202a74">stp_color_t</a></td></tr> <tr><td colspan="2"><h2><a name="func-members"></a> Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga23392fc53078d51fcd14d6d565d56423">stp_color_init</a> (<a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> *v, <a class="el" href="structstp__image.html">stp_image_t</a> *image, size_t steps)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga0cf28c3c9638987df4b1740deadba0cb">stp_color_get_row</a> (<a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> *v, <a class="el" href="structstp__image.html">stp_image_t</a> *image, int row, unsigned *zero_mask)</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__vars.html#ga40c1035f88ac38d77eddb65195b28595">stp_parameter_list_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#gaa282220724877a57738b047140835141">stp_color_list_parameters</a> (const <a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> *v)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga83bc80c9fd84d741099bc20285a1b655">stp_color_describe_parameter</a> (const <a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> *v, const char *name, <a class="el" href="structstp__parameter__t.html">stp_parameter_t</a> *description)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga47d6a8163ef21a6e700b1371228b851d">stp_color_register</a> (const <a class="el" href="structstp__color.html">stp_color_t</a> *color)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga2b62ec8e0afe1b6297bc71466f8a334c">stp_color_unregister</a> (const <a class="el" href="structstp__color.html">stp_color_t</a> *color)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga68c13c36d723e5604507bf33fe629f8b">stp_color_count</a> (void)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the number of available color modules. <a href="#ga68c13c36d723e5604507bf33fe629f8b"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga3b8f62108f3604480e7b89b253527f4a">stp_get_color_by_name</a> (const char *name)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get a color module by its name. <a href="#ga3b8f62108f3604480e7b89b253527f4a"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga68ba525119da39ae854645ae649557d3">stp_get_color_by_index</a> (int idx)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get a color module by its index number. <a href="#ga68ba525119da39ae854645ae649557d3"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga578f80b2bc3937df38ce7e803f5f472c">stp_get_color_by_colorfuncs</a> (<a class="el" href="structstp__colorfuncs__t.html">stp_colorfuncs_t</a> *colorfuncs)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga5a4a4da67cb5c3f1c0a2a9618e46ed50">stp_color_get_name</a> (const <a class="el" href="structstp__color.html">stp_color_t</a> *c)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the short (untranslated) name of a color module. <a href="#ga5a4a4da67cb5c3f1c0a2a9618e46ed50"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__color.html#ga612389b45f09358f6bad0e376c91b057">stp_color_get_long_name</a> (const <a class="el" href="structstp__color.html">stp_color_t</a> *c)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the long (translated) name of a color module. <a href="#ga612389b45f09358f6bad0e376c91b057"></a><br/></td></tr> </table> <hr/><a name="details" id="details"></a><h2>Detailed Description</h2> <p>The color data type is responsible for providing colour conversion features. </p> <p>Color modules provide the actual functionality, so different colour management modules may provide the application with different services (for example, colour profiles). </p> <hr/><h2>Typedef Documentation</h2> <a class="anchor" id="gad1408f9835b72f266ec7c7e1e1202a74"></a><!-- doxytag: member="color.h::stp_color_t" ref="gad1408f9835b72f266ec7c7e1e1202a74" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">typedef struct <a class="el" href="structstp__color.html">stp_color</a> <a class="el" href="structstp__color.html">stp_color_t</a></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <hr/><h2>Function Documentation</h2> <a class="anchor" id="ga68c13c36d723e5604507bf33fe629f8b"></a><!-- doxytag: member="color.h::stp_color_count" ref="ga68c13c36d723e5604507bf33fe629f8b" args="(void)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int stp_color_count </td> <td>(</td> <td class="paramtype">void </td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Get the number of available color modules. </p> <dl class="return"><dt><b>Returns:</b></dt><dd>the number of color modules. </dd></dl> </div> </div> <a class="anchor" id="ga83bc80c9fd84d741099bc20285a1b655"></a><!-- doxytag: member="color.h::stp_color_describe_parameter" ref="ga83bc80c9fd84d741099bc20285a1b655" args="(const stp_vars_t *v, const char *name, stp_parameter_t *description)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void stp_color_describe_parameter </td> <td>(</td> <td class="paramtype">const <a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> * </td> <td class="paramname"><em>v</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const char * </td> <td class="paramname"><em>name</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="structstp__parameter__t.html">stp_parameter_t</a> * </td> <td class="paramname"><em>description</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga612389b45f09358f6bad0e376c91b057"></a><!-- doxytag: member="color.h::stp_color_get_long_name" ref="ga612389b45f09358f6bad0e376c91b057" args="(const stp_color_t *c)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const char* stp_color_get_long_name </td> <td>(</td> <td class="paramtype">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td> <td class="paramname"><em>c</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Get the long (translated) name of a color module. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">c</td><td>the color module to use. </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>the long name. </dd></dl> </div> </div> <a class="anchor" id="ga5a4a4da67cb5c3f1c0a2a9618e46ed50"></a><!-- doxytag: member="color.h::stp_color_get_name" ref="ga5a4a4da67cb5c3f1c0a2a9618e46ed50" args="(const stp_color_t *c)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const char* stp_color_get_name </td> <td>(</td> <td class="paramtype">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td> <td class="paramname"><em>c</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Get the short (untranslated) name of a color module. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">c</td><td>the color module to use. </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>the short name. </dd></dl> </div> </div> <a class="anchor" id="ga0cf28c3c9638987df4b1740deadba0cb"></a><!-- doxytag: member="color.h::stp_color_get_row" ref="ga0cf28c3c9638987df4b1740deadba0cb" args="(stp_vars_t *v, stp_image_t *image, int row, unsigned *zero_mask)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int stp_color_get_row </td> <td>(</td> <td class="paramtype"><a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> * </td> <td class="paramname"><em>v</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="structstp__image.html">stp_image_t</a> * </td> <td class="paramname"><em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"><em>row</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned * </td> <td class="paramname"><em>zero_mask</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga23392fc53078d51fcd14d6d565d56423"></a><!-- doxytag: member="color.h::stp_color_init" ref="ga23392fc53078d51fcd14d6d565d56423" args="(stp_vars_t *v, stp_image_t *image, size_t steps)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int stp_color_init </td> <td>(</td> <td class="paramtype"><a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> * </td> <td class="paramname"><em>v</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="structstp__image.html">stp_image_t</a> * </td> <td class="paramname"><em>image</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">size_t </td> <td class="paramname"><em>steps</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="gaa282220724877a57738b047140835141"></a><!-- doxytag: member="color.h::stp_color_list_parameters" ref="gaa282220724877a57738b047140835141" args="(const stp_vars_t *v)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="group__vars.html#ga40c1035f88ac38d77eddb65195b28595">stp_parameter_list_t</a> stp_color_list_parameters </td> <td>(</td> <td class="paramtype">const <a class="el" href="group__vars.html#ga2d49c94847d18d8b62a214995b14680f">stp_vars_t</a> * </td> <td class="paramname"><em>v</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga47d6a8163ef21a6e700b1371228b851d"></a><!-- doxytag: member="color.h::stp_color_register" ref="ga47d6a8163ef21a6e700b1371228b851d" args="(const stp_color_t *color)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int stp_color_register </td> <td>(</td> <td class="paramtype">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td> <td class="paramname"><em>color</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga2b62ec8e0afe1b6297bc71466f8a334c"></a><!-- doxytag: member="color.h::stp_color_unregister" ref="ga2b62ec8e0afe1b6297bc71466f8a334c" args="(const stp_color_t *color)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int stp_color_unregister </td> <td>(</td> <td class="paramtype">const <a class="el" href="structstp__color.html">stp_color_t</a> * </td> <td class="paramname"><em>color</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga578f80b2bc3937df38ce7e803f5f472c"></a><!-- doxytag: member="color.h::stp_get_color_by_colorfuncs" ref="ga578f80b2bc3937df38ce7e803f5f472c" args="(stp_colorfuncs_t *colorfuncs)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="structstp__color.html">stp_color_t</a>* stp_get_color_by_colorfuncs </td> <td>(</td> <td class="paramtype"><a class="el" href="structstp__colorfuncs__t.html">stp_colorfuncs_t</a> * </td> <td class="paramname"><em>colorfuncs</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="ga68ba525119da39ae854645ae649557d3"></a><!-- doxytag: member="color.h::stp_get_color_by_index" ref="ga68ba525119da39ae854645ae649557d3" args="(int idx)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="structstp__color.html">stp_color_t</a>* stp_get_color_by_index </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>idx</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Get a color module by its index number. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">idx</td><td>the index number. This must not be greater than (total number of papers - 1). </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>a pointer to the color module, or NULL on failure. </dd></dl> </div> </div> <a class="anchor" id="ga3b8f62108f3604480e7b89b253527f4a"></a><!-- doxytag: member="color.h::stp_get_color_by_name" ref="ga3b8f62108f3604480e7b89b253527f4a" args="(const char *name)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="structstp__color.html">stp_color_t</a>* stp_get_color_by_name </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"><em>name</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Get a color module by its name. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">name</td><td>the short unique name. number of papers - 1). </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>a pointer to the color module, or NULL on failure. </dd></dl> </div> </div> </div> <hr class="footer"/><address class="footer"><small>Generated by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.4 </small></address> </body> </html>