Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
yes you can display any picture you want in VC++ application window,
it basically depends on what format your picture file is in is it a bmp or a gif ?,
however the basic idea is to load the picture in a device context (CDC) and then bitblt it into the application window's OnPaint method.
please refer to MSDN the api calls such as CDC::BitBlt etc....
let me know if you need a sample program.
void CPaintDlg::ShowBitmap(CPaintDC *pdc, CWnd *pWnd)
// Convert the pointer to a pointer to the main dialog class
CGraphicsDlg *lpWnd = (CGraphicsDlg*)pWnd;
// Get the loaded bitmap
// Create a device context to load the bitmap into
// Select the bitmap into the compatible device context
CBitmap* pOldBitmap = (CBitmap*)dcMem.SelectObject
// Get the display area available
// Copy and resize the bitmap to the dialog window
pdc->StretchBlt(10, 10, (lRect.Width() - 20),
(lRect.Height() - 20), &dcMem, 0, 0,
bm.bmWidth, bm.bmHeight, SRCCOPY);