Message board for the users of flat assembler.
> Windows > convert winapi 32 reference syntax to FASM syntax (newbie)
DQ 26 Mar 2004, 03:29
I got a stupid newbie question here.
Fasm looks really great. To get some documentation on winapi i downloaded a win 32 api reference. But the syntax seems to be in C. Really annoying, I can read lot about functions, what kind of data they return. But i can't use it when i dont know the exact syntax when i have to convert the winapis definition of functions and structs.
Checking out the examples that comes with FASM isn't really good enough.
If i f.ex . want to use LoadBitmap or GetDIBsection i get into big trouble.
A user in here wrote: 'simply play with the examples...' Come on that can't be true, that i have to guess. Is there any documention that i misssed out there that could give hand?
I need a SIMPLE and straightforward definition of functioncalls to USER32 etc. all types of arguments and data types in FASM syntax. it gotta be possible to get??? Why make a great assembler and no solid documentation?
I haven't got the half trouble with the Intel instruction set, since i have tried Assembly on other computers many years ago.
A few examples are welcome, they will be invested i many hours of coding, and I plan to fix the problem later with a FASM and Winapi for MORONS.
|26 Mar 2004, 03:29||
comrade 26 Mar 2004, 04:06
why don't you look in EXAMPLES directory?
|26 Mar 2004, 04:06||
DQ 26 Mar 2004, 09:27
I thought i was quite clear in my English, but apparently not.
But what the heck, fortunately i got a freind that's programmer so he'll help my out, as he told me (to give you ANOTHER reason than the one above, try read MY example ):" the examples are stupid f.ex because of the naming of the Labels and constants (msg MSG): u can't really grasp whats going on if you don't know it beforehand. Programmers are surppoesed to write comments.
- I'll get it elsewhere, like a cheating husband.
But maybe there is a newer version of FASM with more than 5 examples?? Well last time i checked the Examples link on the net was 'under construction', and the tutorial had something about DOS.
|26 Mar 2004, 09:27||
Vortex 26 Mar 2004, 10:43
Did you download Fasmw? (Flat assembler for Win32 GUI )
It contains various GUI examples.
Code it... That's all...
|26 Mar 2004, 10:43||
pelaillo 26 Mar 2004, 12:48
u can't really grasp whats going on if you don't know it beforehand.
You need to know what's going on when programming for Win32 platform. No matter what language you are using. The win32.hlp is written with C language in mind but still is the main guide used by win32 coders in any language.
Learning assembly is one thing but learning platform specific topics is a totally different beast.
To learn how win32 work you need to follow this steps:
1. To read some book about the matter (You will find mostly in C or C++).
2. To play with the examples (there are a lot inside this board or in board.win32asmcommunity.net or in the member's web pages)
Notes: If you jump the first step you will have a hard time figuring out how examples work but it is possible however.
Download Fresh at fresh.flatassembler.net and Ollydbg debugger.
|26 Mar 2004, 12:48||
_ensein 26 Mar 2004, 13:27
allmost all function arguments are dwords (some functions from opengl for eg need qwords).
parameters can be a value or a pointer to any kind of data (structure).
people tell you to look for the examples because the use of win 32 api reference
is straight forward, most constants and structures are defined in FASM includes which
you can add to your prog with
if you want to know how they are defined just go to include folder in FASM base dir and look for
the equates for win constants and structures or apia/apiw for function calls def...
if you're having trouble with a specific api or struct just post you're code and you will get more help..
|26 Mar 2004, 13:27||
DQ 28 Mar 2004, 16:59
Thanx alot for the answers.
And yes it seems theres only the hard way.
And _ensein: i got that trick from my friend as well. I gives at better undestanding of whats going on.
Apart from that i guessed my problem was to try to extend the template example so it could display a bitmap. So I was asking for trouble
the C=64 was easier!
|28 Mar 2004, 16:59||
Intrinsic 29 Mar 2004, 00:32
QD, at the link below is some tutorials on win32 programming they may help you. And, on this board are the example code written in FASM syntax.
And long live the C64!
|29 Mar 2004, 00:32||
< Last Thread | Next Thread >
Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.