📄 group__bmp__fns.htm
字号:
<td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>h</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap><a class="el" href="struct__BITMAP.htm">BITMAP</a> * </td> <td class="mdname" nowrap> <em>bmp</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Gets image box on a DC and saves it into a BITMAP object. <p>This function gets image box on the specified device context <em>hdc</em>, and saves the image bits into the BITMAP object pointed to by <em>bmp</em>. The image box begins at <em></em>(x,y), and is <em>w</em> wide and <em>h</em> high. You must make sure that <em>bmp->bits</em> is big enough to store the image.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>hdc</em> </td><td>The device context. </td></tr> <tr><td valign="top"></td><td valign="top"><em>x</em> </td><td>The x coordinate in pixels of upper-left corner of the image box. </td></tr> <tr><td valign="top"></td><td valign="top"><em>y</em> </td><td>The y coordinate in pixels of upper-left corner of the image box. </td></tr> <tr><td valign="top"></td><td valign="top"><em>w</em> </td><td>The width of the image box. </td></tr> <tr><td valign="top"></td><td valign="top"><em>h</em> </td><td>The height of the image box. </td></tr> <tr><td valign="top"></td><td valign="top"><em>bmp</em> </td><td>The pointer to the BITMAP object.</td></tr> </table></dl><dl compact><dt><b>Note:</b></dt><dd>Only defined for _USE_NEWGAL. If _USE_NEWGAL not defined, there is will be an analogous function called <em>SaveScreenBox:</em> </dd></dl><div class="fragment"><pre class="fragment"> <span class="keywordtype">void</span> GUIAPI SaveScreenBox (<span class="keywordtype">int</span> x, <span class="keywordtype">int</span> y, <span class="keywordtype">int</span> w, <span class="keywordtype">int</span> h, <span class="keywordtype">void</span>* vbuf)</pre></div><p><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__bmp__fns.htm#ga1">FillBoxWithBitmap</a>, <a class="el" href="group__bmp__struct.htm">Bitmap structure</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga6" doxytag="gdi.h::GetPixelInBitmap"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__gdi__types.htm#ga8">gal_pixel</a> GUIAPI GetPixelInBitmap </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const <a class="el" href="struct__BITMAP.htm">BITMAP</a> * </td> <td class="mdname" nowrap> <em>bmp</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>x</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>y</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Returns the pixel value in a BITMAP object. <p>This function returns the pixel value at the position <em></em>(x,y) in the BITMAP object <em>bmp</em>.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>bmp</em> </td><td>The BITMAP object. </td></tr> <tr><td valign="top"></td><td valign="top"><em>x</em> </td><td>x,y: The position of the pixel in the bitmap relative to the upper-left corner of the bitmap. </td></tr> <tr><td valign="top"></td><td valign="top"><em>y</em> </td><td>x,y: The position of the pixel in the bitmap relative to the upper-left corner of the bitmap. </td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>The pixel value, if the position is out of the bitmap, zero returned.</dd></dl><dl compact><dt><b>Note:</b></dt><dd>Only defined for _USE_NEWGAL.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__bmp__fns.htm#ga7">SetPixelInBitmap</a>, <a class="el" href="group__bmp__struct.htm">Bitmap structure</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga9" doxytag="gdi.h::SaveMainWindowContent"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__simple__types.htm#ga0">BOOL</a> GUIAPI SaveMainWindowContent </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> </td> <td class="mdname" nowrap> <em>hWnd</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>filename</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Saves content of a main window to a file. <p>This function saves the content of the main window <em>hWnd</em> to the image file <em>filename</em>. MiniGUI uses the extension name of the file to determine the format of the image file.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>hWnd</em> </td><td>Handle to the main window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>filename</em> </td><td>The name of the image file.</td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>TRUE on success, otherwise FALSE.</dd></dl><dl compact><dt><b>Note:</b></dt><dd>Only defined for _MISC_SAVESCREEN.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__bmp__load__fns.htm">Bitmap file load/save operations</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga8" doxytag="gdi.h::SaveScreenRectContent"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__simple__types.htm#ga0">BOOL</a> GUIAPI SaveScreenRectContent </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const <a class="el" href="struct__RECT.htm">RECT</a> * </td> <td class="mdname" nowrap> <em>rc</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>filename</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Saves content of a rectangle in the screen to a file. <p>This function saves the content of the rect <em>rc</em> to the image file <em>filename</em>. MiniGUI uses the extension name of the file to determine the format of the image file.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>rc</em> </td><td>The RECT object defined the rectangle in the screen. </td></tr> <tr><td valign="top"></td><td valign="top"><em>filename</em> </td><td>The name of the image file.</td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>TRUE on success, otherwise FALSE.</dd></dl><dl compact><dt><b>Note:</b></dt><dd>Only defined for _MISC_SAVESCREEN.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__bmp__load__fns.htm">Bitmap file load/save operations</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga5" doxytag="gdi.h::ScaleBitmap"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__simple__types.htm#ga0">BOOL</a> GUIAPI ScaleBitmap </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="struct__BITMAP.htm">BITMAP</a> * </td> <td class="mdname" nowrap> <em>dst</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const <a class="el" href="struct__BITMAP.htm">BITMAP</a> * </td>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -