flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
Tomasz Grysztar 07 Mar 2006, 19:40
Works for me. Can you show some example where the problem occurs?
|
|||
![]() |
|
madmatt 07 Mar 2006, 22:29
Here is my win32a.inc file, I combined the normal win32a.inc with the win32ax.inc file. Other than that, the only major thing I've done is to add a lot of extra equates/api's to the fasm include's that didn't come with the standard fasm package. For once the problem is It didn't give me an error message.
![]() |
|||
![]() |
|
Tomasz Grysztar 07 Mar 2006, 22:57
The problem is that you combined it with the macros from win32ax.inc and not from win32axp.inc
|
|||
![]() |
|
madmatt 07 Mar 2006, 23:04
Oh I see, didn't know that's what the p stood for.
![]() ![]() |
|||
![]() |
|
madmatt 08 Mar 2006, 14:18
Maybe you could apply your macro genius one more time and help me solve another problem. I need to call a function like this:
Code: stdcall [psetmode], x0, y0, color But with the pcount macros, this doesn't work anymore. Do you know a way of making this work right? |
|||
![]() |
|
Tomasz Grysztar 08 Mar 2006, 15:04
Why cannot you use "invoke" instead of "stdcall []"?
|
|||
![]() |
|
madmatt 08 Mar 2006, 18:09
I need to use the stdcall[] form because the function I want to call is in the same DLL. also, "psetmode" is not a real function, just a variable that holds a pointer to a function.
its used like this Code: psetmode dd Pset8 ;or Pset16, Pset32 . . proc DDPset8 x0, y0, color mov ecx, [x0] mov edx, [y0] mov eax, [color] cmp ecx, [clipx0] jl DDPset8_e cmp ecx, [clipx1] jge DDPset8_e cmp edx, [clipy0] jl DDPset8_e cmp edx, [clipy1] jge DDPset8_e add ecx, [scanlinetable + edx*4] mov [ecx], al return 0 DDPset8_e: return -1 endp . . proc DDHline x0, x1, y0, color mov eax, [y0] .if eax, l, [clipy0] return DD_OK .elseif eax, ge, [clipy1] return DD_OK .endif mov ecx,[x0] mov edx,[x1] call _HlineClip .if ecx, e, edx stdcall [psetmode], ecx, eax, [color] return DD_OK .endif mov [x0],ecx mov [x1],edx .repeat stdcall [psetmode], [x0], [y0], [color] mov eax,[x1] add [x0],1 .until [x0], a, eax return DD_OK endp |
|||
![]() |
|
Tomasz Grysztar 08 Mar 2006, 18:23
"stdcall [func]"="invoke func", so you can do "invoke psetmode". To have the parameters checked, you need to set it up like
Code: psetmode% = Pset8% |
|||
![]() |
|
madmatt 08 Mar 2006, 23:21
Sorry, your right, I was using invoke [psetmode], I took a nap and am less foggy now, but to late for this post.
![]() Thanks again, Tomasz |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.