RE: QWORD (int64) question

new topic     » goto parent     » topic index » view thread      » older message » newer message

Alright, one last set of questions. These QWORD's will, most probably, be 
signed. So, I'll guess that instead of the line:
    ret = peek4u({q_fptr_retval, 2})
I'd need to put:
    ret = {peek4u(q_fptr_retval), peek4s(q_fptr_retval + 4)}
to get {unsigned low dword, signed high dword}.
And, last question,  how would i then put those two values together, if I 
needed to? I need to test for -1 values. Just multiplying the high dword and 
adding it to the low dword is good enough? Would that account for the 
negative?


>
>
> > From: Elliott Sales de Andrade [mailto:quantum_analyst at hotmail.com]
>
> > Thanks, it looks great. I'd like to know a few other things
> > first though.
> > First off, to get the first param for that function, I'm using
> > GetProcAddress(). I'm using the value returned from
> > open_dll(). I'm not sure
> > if that is right, so I'd like to know.
>
>Using GetProcAddress() is the correct method, although it's actually pretty
>easy to get a pointer to a dll function without explicitly calling
>GetProcAddress().  Just use define_c_variable() instead of define_c_func().
>
>
> > Second, I have a few
> > functions that
> > need to pass floats. So, how would I do this exactly? Just
> > atom_to_float32()
> > and then bytes_to_int() ?  TIA
>
>Yep.
>
>Matt Lewis

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu