For Programmers: Free Programming Magazines  


Home > Archive > Clarion > March 2004 > Q: JOYCAPS typedef & joyGetDevCaps() function









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Q: JOYCAPS typedef & joyGetDevCaps() function
Rick

2004-03-26, 11:01 pm

Declared in C++ as:

typedef struct tagJOYCAPSA {
WORD wMid; /* manufacturer ID */
WORD wPid; /* product ID */
CHAR szPname[MAXPNAMELEN];/* product name (NULL terminated
string) */
UINT wXmin; /* minimum x position value */
UINT wXmax; /* maximum x position value */
UINT wYmin; /* minimum y position value */
UINT wYmax; /* maximum y position value */
UINT wZmin; /* minimum z position value */
UINT wZmax; /* maximum z position value */
UINT wNumButtons; /* number of buttons */
UINT wPeriodMin; /* minimum message period when
captured */
UINT wPeriodMax; /* maximum message period when
captured */
#if (WINVER >= 0x0400)
UINT wRmin; /* minimum r position value */
UINT wRmax; /* maximum r position value */
UINT wUmin; /* minimum u (5th axis) position
value */
UINT wUmax; /* maximum u (5th axis) position
value */
UINT wVmin; /* minimum v (6th axis) position
value */
UINT wVmax; /* maximum v (6th axis) position
value */
UINT wCaps; /* joystick capabilites */
UINT wMaxAxes; /* maximum number of axes supported */
UINT wNumAxes; /* number of axes in use */
UINT wMaxButtons; /* maximum number of buttons supported */
CHAR szRegKey[MAXPNAMELEN];/* registry key */
CHAR szOEMVxD[MAX_JOYSTICKOEMVXDNAME]; /* OEM VxD in use */
#endif

MMRESULT joyGetDevCaps(UINT_PTR uJoyID,LPJOYCAPS pjc,UINT cbjc);

....and for Clarion:

JOYCAPS GROUP,TYPE,PRE()
wMid SIGNED
wPid SIGNED
szPname CSTRING(1000),DIM(32)
wXmin UNSIGNED
wXmax UNSIGNED
wYmin UNSIGNED
wYmax UNSIGNED
wZmin UNSIGNED
wZmax UNSIGNED
wNumButtons UNSIGNED
wPeriodMin UNSIGNED
wPeriodMax UNSIGNED
wRmin UNSIGNED
wRmax UNSIGNED
wUmin UNSIGNED
wUmax UNSIGNED
wVmin UNSIGNED
wVmax UNSIGNED
wCaps UNSIGNED
wMaxAxes UNSIGNED
wNumAxes UNSIGNED
wMaxButtons UNSIGNED
szRegKey CSTRING(1000),DIM(32)
szOEMVxD CSTRING(1000),DIM(260)
END

joyGetDevCapsA(LONG,*JOYCAPS,LONG),LONG,
PASCAL,RAW

Is this correct?

In Clarion, it doesn't return any results and I don't understand why
not. When Visual c++ is used, it works okay.

Thanks in advance for any help!
-Rick
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com