ExternalLibrary - passing the pointer to an integer value

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

ExternalLibrary - passing the pointer to an integer value

Günther Schmidt
Hi,

there is a function call in an external library (glut32.dll) which
expects 2 arguments, the first one to be the *pointer* to an integer.

Aparently the function will manipulate the value.

How do I do that?

I've tried passing things like:

        5 yourAdress
        5 asDword
        ... etc

nothing worked, that doesn't seem to do the trick.

Günther


Reply | Threaded
Open this post in threaded view
|

Re: ExternalLibrary - passing the pointer to an integer value

Schwab,Wilhelm K
Günther,

> there is a function call in an external library (glut32.dll) which
> expects 2 arguments, the first one to be the *pointer* to an integer.
>
> Aparently the function will manipulate the value.
>
> How do I do that?
>
> I've tried passing things like:
>
>     5 yourAdress
>     5 asDword
>     ... etc
>
> nothing worked, that doesn't seem to do the trick.

Try creating a DWORD, put any seed value you want in it, and then pass
the DWORD as the argument.  Do not take the address yourself; the VM
will do that for you.

Have a good one,

Bill


--
Wilhelm K. Schwab, Ph.D.
[hidden email]


Reply | Threaded
Open this post in threaded view
|

Re: ExternalLibrary - passing the pointer to an integer value

Günther Schmidt
Bill Schwab schrieb:
> Try creating a DWORD, put any seed value you want in it, and then pass
> the DWORD as the argument.  Do not take the address yourself; the VM
> will do that for you.
>
> Have a good one,
>
> Bill
>
>

Thanks Bill,

that worked.