mfc_image_load - 8BitsCoding/RobotMentor GitHub Wiki
// Dlg .h
private:
CImage m_png_image;
// Dlg .cpp
BOOL CLoadPngDlg::OnInitDialog()
{
// ...
m_png_image.Load(L"image.png");
}
// Dlg .cpp
void CLoadPngDlg::OnPaint()
{
if()
{
// ...
}
else
{
CPaintDC dc(this);
// 해당 다이얼로그의 dc를 받아오고
m_png_image.Draw(dc, 0, 0);
// m_png_image를 dc에 그리게 된다.
// CDialogEx::OnPaint();
}
}