Click here to Skip to main content
16,008,719 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Exception in CPropertySheet::OnInitDialog() Pin
Antony M Kancidrowski14-Dec-04 1:12
Antony M Kancidrowski14-Dec-04 1:12 
GeneralRe: Exception in CPropertySheet::OnInitDialog() Pin
Avya15-Dec-04 21:47
Avya15-Dec-04 21:47 
GeneralDelete Temporary Internet File Pin
Rajesh_K_Sharma13-Dec-04 23:06
Rajesh_K_Sharma13-Dec-04 23:06 
GeneralRe: Delete Temporary Internet File Pin
Ravi Bhavnani14-Dec-04 0:30
professionalRavi Bhavnani14-Dec-04 0:30 
GeneralSUCCES->tooltip/groupbox Pin
V.13-Dec-04 22:59
professionalV.13-Dec-04 22:59 
QuestionAny Suggestin about shrink/ stretch a BMP? Pin
ytod13-Dec-04 22:25
ytod13-Dec-04 22:25 
AnswerRe: Any Suggestin about shrink/ stretch a BMP? Pin
namaskaaram13-Dec-04 22:43
namaskaaram13-Dec-04 22:43 
GeneralRe: Any Suggestin about shrink/ stretch a BMP? Pin
ytod13-Dec-04 23:13
ytod13-Dec-04 23:13 
I knew that...;P
Maybe need to talk in more detail...
Some function would provide the BITMAPINFOHEADER and Bitmap buffer data. I wanna change the size of the resulting BMP. The step I thought was that:

1. call CreateCompatibleDC( ) to create a memory DC.
2. call CreateCompatibleBitmap( ), get the handle of a bitmap and use last-created memory DC to select it.
3. call memcpy( ) to copy the data to the last-created compatible bitmap.
4. call StretchBlt( ) from the memory DC to the dialog DC( or memory DC number 2 ).

For I need to save time, the data of the BMP after stretch need to be saved. So...the following work may required to be done only once.
5. call GetCurrentBitmap for the dialog DC( or memory DC number 2 ).
6. call CBitmap::GetBitmapBits( ), get the data( upset-down, need to flip. )
7. CreateDIBSection( ) for the new data in new size.

8. OK, next time when repaint is required, simply use a memory DC to select these bitmap handles and call BitBlt from a memory DC to dialog DC.

( The steps concerning with the deleting of some temp GDI objects are omitted. )

OMG! Too many steps... Is there a simpler way than that? Thanks!
GeneralRe: Any Suggestin about shrink/ stretch a BMP? Pin
namaskaaram14-Dec-04 0:48
namaskaaram14-Dec-04 0:48 
GeneralWindows NT Authentication Pin
rasha200313-Dec-04 22:20
rasha200313-Dec-04 22:20 
GeneralRe: Windows NT Authentication Pin
Antony M Kancidrowski14-Dec-04 1:09
Antony M Kancidrowski14-Dec-04 1:09 
GeneralRe: Windows NT Authentication Pin
rasha200314-Dec-04 3:55
rasha200314-Dec-04 3:55 
GeneralRe: Windows NT Authentication Pin
Antony M Kancidrowski14-Dec-04 4:08
Antony M Kancidrowski14-Dec-04 4:08 
Generalweird behaviour with escape character Pin
doneirik13-Dec-04 22:18
doneirik13-Dec-04 22:18 
GeneralRe: weird behaviour with escape character Pin
AslFunky14-Dec-04 1:33
AslFunky14-Dec-04 1:33 
GeneralRe: weird behaviour with escape character Pin
doneirik14-Dec-04 1:54
doneirik14-Dec-04 1:54 
GeneralRe: weird behaviour with escape character Pin
David Crow14-Dec-04 2:13
David Crow14-Dec-04 2:13 
GeneralRe: weird behaviour with escape character Pin
doneirik14-Dec-04 3:47
doneirik14-Dec-04 3:47 
GeneralVB Callback function with string in VC DLL Pin
Michael Olsen13-Dec-04 21:59
Michael Olsen13-Dec-04 21:59 
GeneralDirectShow : Linker Error Pin
tspramod13-Dec-04 21:40
tspramod13-Dec-04 21:40 
GeneralRe: DirectShow : Linker Error Pin
Sujan Christo13-Dec-04 21:53
Sujan Christo13-Dec-04 21:53 
GeneralRe: DirectShow : Linker Error Pin
ytod13-Dec-04 22:18
ytod13-Dec-04 22:18 
Generalcommunication throught USB Pin
tibiz13-Dec-04 21:23
tibiz13-Dec-04 21:23 
GeneralRe: communication throught USB Pin
namaskaaram13-Dec-04 21:57
namaskaaram13-Dec-04 21:57 
GeneralRe: communication throught USB Pin
tibiz14-Dec-04 1:17
tibiz14-Dec-04 1:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.