请大家帮我
解决方案 »
- 请问怎样根据不断获取的point来模拟mosemove事件?
- 直方图统计
- 100分急求!!!!SDI程序中,如何在CWinapp类中获得CDocument的指针??
- 如何把一个颜色的二维数组转换成CBitmap
- 有关控件背景透过的问题,征集思路,不要代码。
- 怎样才能看清用繁体系统的朋友的贴
- 关于csocket的一个c/s程序的错误
- 获取cpu占用率,有事不准
- 使用 ShowWindow(SW_MAXIMIZE) 后窗口最大化了,但仍然可以被移动???
- 如何在最短的时间内掌握VC
- .h和.cpp文件前面的说明,如时间,日期等,高手是如何加的?ctrl+c和v还是assist还是别的什么方法?
- sourceFourge的CVS怎么进?密码anonymous怎么进不去?有who能够给偶一个例子?谢谢大家
BOOL BitBlt( int x, int y, int nWidth, int nHeight, CDC* pSrcDC, int xSrc, int ySrc, DWORD dwRop );Return ValueNonzero if the function is successful; otherwise 0.ParametersxSpecifies the logical x-coordinate of the upper-left corner of the destination rectangle.ySpecifies the logical y-coordinate of the upper-left corner of the destination rectangle.nWidthSpecifies the width (in logical units) of the destination rectangle and source bitmap.nHeightSpecifies the height (in logical units) of the destination rectangle and source bitmap.pSrcDCPointer to a CDC object that identifies the device context from which the bitmap will be copied. It must be NULL if dwRop specifies a raster operation that does not include a source.xSrcSpecifies the logical x-coordinate of the upper-left corner of the source bitmap.ySrcSpecifies the logical y-coordinate of the upper-left corner of the source bitmap.dwRopSpecifies the raster operation to be performed. Raster-operation codes define how the GDI combines colors in output operations that involve a current brush, a possible source bitmap, and a destination bitmap. The following lists raster-operation codes for dwRop and their descriptions: BLACKNESS Turns all output black.
DSTINVERT Inverts the destination bitmap.
MERGECOPY Combines the pattern and the source bitmap using the Boolean AND operator.
MERGEPAINT Combines the inverted source bitmap with the destination bitmap using the Boolean OR operator.
NOTSRCCOPY Copies the inverted source bitmap to the destination.
NOTSRCERASE Inverts the result of combining the destination and source bitmaps using the Boolean OR operator.
PATCOPY Copies the pattern to the destination bitmap.
PATINVERT Combines the destination bitmap with the pattern using the Boolean XOR operator.
PATPAINT Combines the inverted source bitmap with the pattern using the Boolean OR operator. Combines the result of this operation with the destination bitmap using the Boolean OR operator.
SRCAND Combines pixels of the destination and source bitmaps using the Boolean AND operator.
SRCCOPY Copies the source bitmap to the destination bitmap.
SRCERASE Inverts the desination bitmap and combines the result with the source bitmap using the Boolean AND operator.
SRCINVERT Combines pixels of the destination and source bitmaps using the Boolean XOR operator.
SRCPAINT Combines pixels of the destination and source bitmaps using the Boolean OR operator.
WHITENESS Turns all output white.
For a complete list of raster-operation codes, seeAbout Raster Operation Codes in the Appendices section of the Win32 SDK Programmer’s Reference.ResCopies a bitmap from the source device context to this current device context. The application can align the windows or client areas on byte boundaries to ensure that the BitBlt operations occur on byte-aligned rectangles. (Set the CS_BYTEALIGNWINDOW or CS_BYTEALIGNCLIENT flags when you register the window classes.) BitBlt operations on byte-aligned rectangles are considerably faster than BitBlt operations on rectangles that are not byte aligned. If you want to specify class styles such as byte-alignment for your own device context, you will have to register a window class rather than relying on the Microsoft Foundation classes to do it for you. Use the global function AfxRegisterWndClass.GDI transforms nWidth and nHeight, once by using the destination device context, and once by using the source device context. If the resulting extents do not match, GDI uses the Windows StretchBlt function to compress or stretch the source bitmap as necessary.If destination, source, and pattern bitmaps do not have the same color format, the BitBlt function converts the source and pattern bitmaps to match the destination. The foreground and background colors of the destination bitmap are used in the conversion. When the BitBlt function converts a monochrome bitmap to color, it sets white bits (1) to the background color and black bits (0) to the foreground color. The foreground and background colors of the destination device context are used. To convert color to monochrome, BitBlt sets pixels that match the background color to white and sets all other pixels to black. BitBlt uses the foreground and background colors of the color device context to convert from color to monochrome.Note that not all device contexts support BitBlt. To check whether a given device context does support BitBlt, use the GetDeviceCaps member function and specify the RASTERCAPS index.