if (memDC == null) {
memDC = gdi.CreateCompatibleDC(screenDC);
}
if (hBitmap == null || !win.getSize().equals(bitmapSize)) {
if (hBitmap != null) {
gdi.DeleteObject(hBitmap);
hBitmap = null;
}
BITMAPINFO bmi = new BITMAPINFO();
bmi.bmiHeader.biWidth = ww;
bmi.bmiHeader.biHeight = wh;