Click here to Skip to main content
15,902,938 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: why execution time of program varies with identical initial settings? Pin
jianzhuhuai18-Nov-09 3:22
jianzhuhuai18-Nov-09 3:22 
GeneralRe: why execution time of program varies with identical initial settings? Pin
BobInNJ19-Nov-09 5:34
BobInNJ19-Nov-09 5:34 
GeneralRe: why execution time of program varies with identical initial settings? Pin
jianzhuhuai23-Nov-09 0:34
jianzhuhuai23-Nov-09 0:34 
Question[Message Deleted] Pin
kumar sanghvi13-Nov-09 23:56
kumar sanghvi13-Nov-09 23:56 
AnswerRe: singleton Pin
Richard MacCutchan14-Nov-09 0:38
mveRichard MacCutchan14-Nov-09 0:38 
Questioninitialisation inside struct Pin
kumar sanghvi13-Nov-09 23:20
kumar sanghvi13-Nov-09 23:20 
AnswerRe: initialisation inside struct Pin
Richard MacCutchan14-Nov-09 0:47
mveRichard MacCutchan14-Nov-09 0:47 
Questionhow to display a bitmap which have 24 colors Pin
tfzxyinhao13-Nov-09 23:05
tfzxyinhao13-Nov-09 23:05 
hi,everyone recent i was study how to use ffmpeg to make a media player,but now i miss a question that how to show a bitmap on dc.


CRect rt;
GetClientRect(&rt);
CClientDC dc(this);
CDC mem;
mem.CreateCompatibleDC(&dc);
CBitmap bp;
bp.CreateBitmap(width,height,1,24,lpbits);
mem.SelectObject(&bp);
dc.StretchBlt(0,0,rt.Width(),rt.Height(),&mem,0,0,width,height,SRCCOPY);
but the code not work
lpbits is pointer to the data of bitmap,"height" is the height of bitmap "width" is the width of bitmap
and the size of one pixel's color is three byte

lpbits height width 24 is the all data we know about this bitmap
can you help me to show the data on DC
AnswerRe: how to display a bitmap which have 24 colors Pin
Hadi Dayvary14-Nov-09 1:02
professionalHadi Dayvary14-Nov-09 1:02 
GeneralRe: how to display a bitmap which have 24 colors Pin
tfzxyinhao14-Nov-09 2:14
tfzxyinhao14-Nov-09 2:14 
GeneralRe: how to display a bitmap which have 24 colors Pin
Hadi Dayvary14-Nov-09 2:26
professionalHadi Dayvary14-Nov-09 2:26 
GeneralRe: how to display a bitmap which have 24 colors Pin
tfzxyinhao14-Nov-09 3:00
tfzxyinhao14-Nov-09 3:00 
GeneralRe: how to display a bitmap which have 24 colors Pin
Hadi Dayvary14-Nov-09 3:26
professionalHadi Dayvary14-Nov-09 3:26 
GeneralRe: how to display a bitmap which have 24 colors Pin
jianzhuhuai18-Nov-09 2:38
jianzhuhuai18-Nov-09 2:38 
QuestionWhen is "bmp" not equal to "bmp"? Pin
Sauce!13-Nov-09 20:34
Sauce!13-Nov-09 20:34 
AnswerRe: When is "bmp" not equal to "bmp"? Pin
«_Superman_»14-Nov-09 9:28
professional«_Superman_»14-Nov-09 9:28 
GeneralRe: When is "bmp" not equal to "bmp"? Pin
Sauce!14-Nov-09 13:08
Sauce!14-Nov-09 13:08 
QuestionVertical Text in OnDraw() Pin
Anu_Bala13-Nov-09 20:14
Anu_Bala13-Nov-09 20:14 
AnswerRe: Vertical Text in OnDraw() Pin
Hadi Dayvary13-Nov-09 22:02
professionalHadi Dayvary13-Nov-09 22:02 
QuestionHow to suspended other program's Main Window? Pin
wangningyu13-Nov-09 16:47
wangningyu13-Nov-09 16:47 
AnswerRe: How to suspended other program's Main Window? Pin
enhzflep14-Nov-09 13:20
enhzflep14-Nov-09 13:20 
QuestionSet Dynamic content on webbrowser control Pin
Arnon A13-Nov-09 10:35
Arnon A13-Nov-09 10:35 
QuestionLNK2019 error, unresolved external symbol __thiscall Pin
Dan Senior13-Nov-09 10:15
Dan Senior13-Nov-09 10:15 
AnswerRe: LNK2019 error, unresolved external symbol __thiscall Pin
Garth J Lancaster13-Nov-09 11:29
professionalGarth J Lancaster13-Nov-09 11:29 
GeneralRe: LNK2019 error, unresolved external symbol __thiscall Pin
Dan Senior23-Nov-09 11:25
Dan Senior23-Nov-09 11:25 

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.