flat assembler
Message board for the users of flat assembler.
Index
> Windows > Problem with bitmaps |
Author |
|
Madis731 07 Aug 2006, 07:18
1) you need
Code:
directory RT_BITMAP,bitmaps
to make it work under FASM 1.66 2) It draws the bitmap behind the Code: invoke CreateWindowEx,0,_StaticClassName,NULL,WS_CHILD+WS_VISIBLE+WS_BORDER,5,28,325,235,[hwnd],NULL,[wc.hInstance],NULL so very little can be seen. Try if you can fix it yourself now - I don't know what are you trying to do with that BMP. |
|||
07 Aug 2006, 07:18 |
|
Defsanguje 07 Aug 2006, 15:15
Madis731 wrote: 1) you need I just wanted to display it. Thanks, Code:
directory RT_BITMAP,bitmaps
worked |
|||
07 Aug 2006, 15:15 |
|
Reverend 07 Aug 2006, 22:33
There are too ways for drawing a bitmap. First is by obtaining device context (dc) when WM_PAINT is sent. Then you draw it in a similar way you posted. But if you create a static with SS_BITMAP style you can do it the other (simplier) way:
Code: invoke CreateWindowEx,0,_StaticClassName,NULL,WS_CHILD+WS_VISIBLE+SS_BITMAP,10,32,600,600,[hwnd],IDR_LOGO,[wc.hInstance],NULL mov [handle_of_static], eax ... invoke LoadBitmap, [wc.hInstance], IDR_LOGO mov [handle_of_bitmap], eax ... invoke SendMessage, [handle_of_static], STM_SETIMAGE, IMAGE_BITMAP, [handle_of_bitmap] EDIT: If you choose the first way (drawing), do not create statics with SS_BITMAP as they're useless then. |
|||
07 Aug 2006, 22:33 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.