ok Im new to programming in ASM
First I tried to learn directX7 with C++/ASM but for the life of me I could not compile one example, so I went to openGL with DevC++ and I had trouble compiling anything in OGL but their (one) example. so then I found this place ;)
I like that with MASM32 I can access openGL commands and actually compile them. I bought the "red" book and Im learning all about openGL right now.. very interesting stuff.

Now looking thru the include files and macros, Ive noticed there are many missing macros for the GLU32 commands and there is nothing at all for the GLUT..
I have some examples that Id like to try out, but they all require the GLUT for input and other things..
Is there anyone who has includes that would allow me to access GLUT commands and/or the rest of the GLU32 commands?
If not, can someone point me in the right direction as to how I could create my own? Is there a reason why these macros+files were not created? I really want to use advanced graphics but I dont like C++ so Id like to avoid it as much as possible..
Posted on 2001-08-22 11:32:54 by closed_casket
hey people, you might think Im dumb or whatever but I think its a fairly reasonable question. Im not asking for you to tell me how to make a game or anything, Im simply asking how I can access the full range of openGL commands, including GLU and the GLUT, thru MASM32 and macros.
I realize what GLUT is and I know what its for, and I know you people probably use another method for creating windows and taking input, if thats the case Id like a reply to tell me how stupid I am and what I should do instead of nothing at all... thanks
Posted on 2001-08-22 17:37:08 by closed_casket
More people frequent this board on the weekend. Please, don't be so hasty in judging yourself. Just keep plugging away to find your own answers, and if there is someone here that can help you, I'm sure they will respond. Sorry, but I can provide no insight on this. There are other resources maybe, or is this your last hope?

Click here to try Google: OpenGL GLU Assembly!. :alright:
Posted on 2001-08-22 17:45:47 by bitRAKE
sorry I probably shouldve waited longer before posting again.. Ive been to a ton of sites (including yours and almost all the links) ;) dealing with openGL and MASM32 and the combination of the two, but maybe I missed something. I have all the include files and whatnot to compile the demos I found, and they compile nicely, but looking thru those files I see that there are a few problems, like PROTO's with paramaters that do not match the corresponding opengl functions paramaters, and the glu.mac file I have only has macros for like 3 of the commands, and when I looked it up in the blue book there are a ton more.. Question-If I make a macro and a PROTO for a glu function and threw it into the include files with the others, would that allow me to invoke them? Im new to all this so hopefully I make sense..
Posted on 2001-08-22 19:58:39 by closed_casket
The PROTOs exist in glu.def for a lot of stuff in glu.lib. I would think that you should be able to call those functions. The difference that you speak of is because you can have to pass the object that the function operates on. This happens when you translate from HLL to LLL. I don't know why macros don't exist for the other functions. Let us know how it goes?
Posted on 2001-08-22 20:22:31 by bitRAKE
So then if the C specification for a function is:


gluTessVertex
NAME
gluTessVertex -- specify a vertex on a polygon
C SPECIFICATION
void gluTessVertex(GLUtriangulatorObj *tobj,GLdouble v[3], void *data)


the function has 3 parameters, so this proto
makes sense to me:

gluTessVertex PROTO :DWORD,:DWORD,:DWORD


But then theres this one:

gluUnProject -- map window coordinates to object coordinates
C SPECIFICATION
int gluUnProject(GLdouble winx,
GLdouble winy,
GLdouble winz,
const GLdouble modelMatrix[16],
const GLdouble projMatrix[16],
const GLint viewport[4],
GLdouble *objx,
GLdouble *objy,
GLdouble *objz)


only 9 parameters, right?? So why is it like this in the glu.def file?

gluUnProject PROTO :DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD

that looks like 12 parameters to me.. 12 DWORDS, Am I missing something or did someone mess up? I want to learn how to do all this myself (making .defs with Protos and macros to invoke functions) but Id need to know how this all works first.
Posted on 2001-08-24 11:10:21 by closed_casket
I am often wrong, but no more than half the time. :)
Posted on 2001-08-24 11:41:47 by bitRAKE
was that you who made that? And for real now should those numbers be different? should there really be 9 DWORDS instead of 12?
Posted on 2001-08-25 17:57:56 by closed_casket
Come on people this is a serious question !

When you define a proto do you need to have the same number of DWORDS as the number of arguments for the function you are trying to call? Are there problems that could come from having too many dwords in a proto declaration?

Lets say I have a .DLL.. which contains lots of useful functions I want to use inside it. Say theres a magic function inside called :

Make_Game(gametype, speed, whatever)

now would I be wrong to assume the PROTO should be:

Make_Game PROTO :DWORD,:DWORD,:DWORD

3 dwords, one for each argument in the function.. right?


Would it cause any problems to have it be lots more like this

Make_Game PROTO :DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD


?
Posted on 2001-09-01 12:06:20 by closed_casket