ok im trying to create cursor using gdi. i can't even find tutorial how to use customize cursor, i can find so many tutorials for c#. all i know that i use these two functions to set cursor,setcursor and loadcursor that is it thanks Rami
+1
A:
You can create your own cursor using CreateCursor(). The last two parameters defined the actual pixel data. This gives you a HCURSOR handle.
Once created, you can use it with SetCursor(HCURSOR handle).
the link you gave me for createcursor() i found a link for an example http://msdn.microsoft.com/en-us/library/ms648380(v=VS.85).aspx#_win32_Displaying_a_Cursorthe problem is they didn't use any gdi to create the they only used some 00xFF......... any idea?
Ramiz Toma
2010-08-11 08:46:22
They use hardcoded cursor data. IF you want, you can load a bitmap using LoadBitmap() and then read out the pixel values using GetDIBits(). A image processing library like DevIL can help you with other formats than BMP.
2010-08-11 08:51:28
i don't want to load an image, i have gdi code that draws a fill eclipse
Ramiz Toma
2010-08-11 08:57:21
OK, then draw the ellipse to a HDC that links to the bitmap using CreateCompatibleDC(0), SelectObject() and DrawEllipse(). Then use GetDIBits() to get the bitmap data.
2010-08-11 09:12:39
in createcursor() what should i put in pvANDPlane and pvXORPlane
Ramiz Toma
2010-08-11 19:02:38
are you here? i really need help i can't find no one to help me,or you can help me on how to load cursor from file
Ramiz Toma
2010-08-12 05:32:05
The AND mask is 1 bit per pixel and specifies which pixels are transparent and which show colors. The AND mask is read first while displaying an icon to decide which areas of the image are affected by the background. (source: en.wikipedia)
2010-08-12 07:57:23