News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

iid param in DirectDraw7

Started by satpro, June 29, 2012, 01:17:07 AM

Previous topic - Next topic

satpro

I was wondering if anyone could help me understand how to pass this param in the DirectDrawCreateEx call.  I'm working with Dx7.  Since it's a GUID, it doesn't pass directly in Invoke, but I have had some luck with this:

DATA SECTION
IID_IDirectDraw7    GUID    GUID_IID_IDirectDraw7

CODE SECTION
invoke DirectDrawCreateEx, NULL, ADDR ptrIDirectDraw, ADDR IID_IDirectDraw7, NULL

Is this how to go about it?

qWord

yes, you must pass a pointer to the GUID.
AFAICS it should work.
MREAL macros - when you need floating point arithmetic while assembling!

satpro

#2
Thank you, q.