Is there any way to obtain a
HICON from a
ID2D1Bitmap * using Direct2D? I am using this function to load the bitmap.
The reason I ask is because I am creating my level editor tool and would like to draw a PNG image on a standard button control.
I know that you can do this using GDI+:
HBITMAP hBitmap; Gdiplus::Bitmap b(L"a.png"); b.GetHBITMAP(NULL, &hBitmap); SendMessage(GetDlgItem(hDlg, IDC_BUTTON1), BM_SETIMAGE, IMAGE_BITMAP, (LPARAM)hBitmap);
Is there any equivalent, simple solution using Direct2D? If possible, I would like to render multiple PNG files (some with transparency) on a single button.