I'm having problems with the basics of windows api programming.
before you attack me i do have a book, and i did read on-line tutorials on the subject, but they are so blur.
all i need is a simple explanation on:
1. what is a Device Context ?
2. how does the SelectObject() works, what does it mean selecting an object?
3. when i want to use an object or draw something why do i need to create a compatibleDC, like so:
HDC hDC, memDC;
hDC = GetDC(hwnd);
memDC = CreateCompatibleDC(hdc);
hBrush = (HBRUSH) GetStockObject(WHITE_BRUSH);
PatBlt(memDC, 0, 0, 100, 100, PATCOPY);
BitBlt(hDC, 0, 0, 100, 100, memDC, 0, 0, SRCCOPY);
thank you very much,