⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gdk-gdkrgb.html

📁 最新gtk中文资料集
💻 HTML
📖 第 1 页 / 共 5 页
字号:
                                                         <a class="link" href="gdk-GdkRGB.html#GdkRgbDither">GdkRgbDither</a> dith,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar">guchar</a> *buf,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> rowstride,                                                         <a class="link" href="gdk-GdkRGB.html#GdkRgbCmap">GdkRgbCmap</a> *cmap);</pre><p>Draws an indexed image in the drawable, using a <a class="link" href="gdk-GdkRGB.html#GdkRgbCmap"><span class="type">GdkRgbCmap</span></a> to assignactual colors to the color indices.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em>&#160;:</span></p></td><td>The <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a> to draw in (usually a <a class="link" href="gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a>).</td></tr><tr><td><p><span class="term"><em class="parameter"><code>gc</code></em>&#160;:</span></p></td><td>The graphics context.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>x</code></em>&#160;:</span></p></td><td>The x coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>y</code></em>&#160;:</span></p></td><td>The y coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>width</code></em>&#160;:</span></p></td><td>The width of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>height</code></em>&#160;:</span></p></td><td>The height of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>dith</code></em>&#160;:</span></p></td><td>A <a class="link" href="gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> value, selecting the desired dither mode.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>buf</code></em>&#160;:</span></p></td><td>The pixel data, represented as 8-bit color indices.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>rowstride</code></em>&#160;:</span></p></td><td>The number of bytes from the start of one row in <em class="parameter"><code>buf</code></em> to thestart of the next.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>cmap</code></em>&#160;:</span></p></td><td>The <a class="link" href="gdk-GdkRGB.html#GdkRgbCmap"><span class="type">GdkRgbCmap</span></a> used to assign colors to the color indices.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3127258"></a><h3><a name="gdk-draw-gray-image"></a>gdk_draw_gray_image ()</h3><a class="indexterm" name="id3127271"></a><pre class="programlisting">void                gdk_draw_gray_image                 (<a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable">GdkDrawable</a> *drawable,                                                         <a class="link" href="gdk-Graphics-Contexts.html#GdkGC">GdkGC</a> *gc,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> x,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> y,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> width,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> height,                                                         <a class="link" href="gdk-GdkRGB.html#GdkRgbDither">GdkRgbDither</a> dith,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar">guchar</a> *buf,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> rowstride);</pre><p>Draws a grayscale image in the drawable.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em>&#160;:</span></p></td><td>The <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a> to draw in (usually a <a class="link" href="gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a>).</td></tr><tr><td><p><span class="term"><em class="parameter"><code>gc</code></em>&#160;:</span></p></td><td>The graphics context.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>x</code></em>&#160;:</span></p></td><td>The x coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>y</code></em>&#160;:</span></p></td><td>The y coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>width</code></em>&#160;:</span></p></td><td>The width of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>height</code></em>&#160;:</span></p></td><td>The height of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>dith</code></em>&#160;:</span></p></td><td>A <a class="link" href="gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> value, selecting the desired dither mode.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>buf</code></em>&#160;:</span></p></td><td>The pixel data, represented as 8-bit gray values.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>rowstride</code></em>&#160;:</span></p></td><td>The number of bytes from the start of one row in <em class="parameter"><code>buf</code></em> to thestart of the next.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3127525"></a><h3><a name="gdk-draw-rgb-32-image"></a>gdk_draw_rgb_32_image ()</h3><a class="indexterm" name="id3127539"></a><pre class="programlisting">void                gdk_draw_rgb_32_image               (<a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable">GdkDrawable</a> *drawable,                                                         <a class="link" href="gdk-Graphics-Contexts.html#GdkGC">GdkGC</a> *gc,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> x,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> y,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> width,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> height,                                                         <a class="link" href="gdk-GdkRGB.html#GdkRgbDither">GdkRgbDither</a> dith,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar">guchar</a> *buf,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> rowstride);</pre><p>Draws a padded RGB image in the drawable. The image is stored as onepixel per 32-bit word. It is laid out as a red byte, a green byte, ablue byte, and a padding byte.</p><p>It's unlikely that this function will give significant performancegains in practice. In my experience, the performance gain from havingpixels aligned to 32-bit boundaries is cancelled out by the increasedmemory bandwidth.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em>&#160;:</span></p></td><td>The <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a> to draw in (usually a <a class="link" href="gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a>).</td></tr><tr><td><p><span class="term"><em class="parameter"><code>gc</code></em>&#160;:</span></p></td><td>The graphics context.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>x</code></em>&#160;:</span></p></td><td>The x coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>y</code></em>&#160;:</span></p></td><td>The y coordinate of the top-left corner in the drawable.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>width</code></em>&#160;:</span></p></td><td>The width of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>height</code></em>&#160;:</span></p></td><td>The height of the rectangle to be drawn.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>dith</code></em>&#160;:</span></p></td><td>A <a class="link" href="gdk-GdkRGB.html#GdkRgbDither"><span class="type">GdkRgbDither</span></a> value, selecting the desired dither mode.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>buf</code></em>&#160;:</span></p></td><td>The pixel data, represented as padded 32-bit data.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>rowstride</code></em>&#160;:</span></p></td><td>The number of bytes from the start of one row in <em class="parameter"><code>buf</code></em> to thestart of the next.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3127803"></a><h3><a name="gdk-draw-rgb-32-image-dithalign"></a>gdk_draw_rgb_32_image_dithalign ()</h3><a class="indexterm" name="id3127816"></a><pre class="programlisting">void                gdk_draw_rgb_32_image_dithalign     (<a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable">GdkDrawable</a> *drawable,                                                         <a class="link" href="gdk-Graphics-Contexts.html#GdkGC">GdkGC</a> *gc,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> x,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> y,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> width,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> height,                                                         <a class="link" href="gdk-GdkRGB.html#GdkRgbDither">GdkRgbDither</a> dith,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar">guchar</a> *buf,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> rowstride,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> xdith,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> ydith);</pre><p>Like <a class="link" href="gdk-GdkRGB.html#gdk-draw-rgb-32-image"><code class="function">gdk_draw_rgb_32_image()</code></a>, but allows you to specify the ditheroffsets. See <a class="link" href="gdk-GdkRGB.html#gdk-draw-rgb-image-dithalign"><code class="function">gdk_draw_rgb_image_dithalign()</code></a> for more details.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em>&#160;:</span></p></td><td> a <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>gc</code></em>&#160;:</span></p></td>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -