PEXUpdatePickMeasure(3) — Subroutines
Name
PEXUpdatePickMeasure - Update Pick Measure
Synopsis
void PEXUpdatePickMeasure(Display ∗display, PEXPickMeasure pick_measure, int pick_device_type, PEXPickRecord ∗pick_record)
Arguments
displayA pointer to a display structure returned by a successful XOpenDisplay call.
pick_measure
The resource identifier of the pick measure.
pick_device_type
The pick device type (PEXPickDeviceDCHitBox or PEXPickDeviceNPCHitVolume).
pick_recordA pointer to the pick data record.
Returns
None
Description
This function updates the specified pick measure resource. If the update causes a primitive to be picked, the pick measure’s pick status will be set to PEXPick and the pick path attribute will be set to the path of the picked primitive. If no primitive was picked, the pick status will be set to PEXNoPick.
The pick path can be used for echoing when the pick measure is created. However, it is not used as a start path from which to start picking.
The input record is a pointer to data used to update the pick measure and depends on the pick device type specified when the pick measure was created. If the pick device type is PEXPickDeviceDCHitBox, the input record should point to a data structure of type PEXPDDCHitBox. If the pick device type is PEXPickDeviceNPCHitVolume, the input record should point to a data structure of type PEXPDNPCHitVolume.
Data Structures
typedef XID PEXPickMeasure;
typedef union {
PEXPDNPCHitVolume volume;
PEXPDDCHitBox box;
PEXPickDataRecord data;
} PEXPickRecord;
typedef PEXNPCSubVolume PEXPDNPCHitVolume;
typedef struct {
PEXCoord min;
PEXCoord max;
} PEXNPCSubVolume;
typedef struct {
float x;
float y;
float z;
} PEXCoord;
typedef struct {
PEXDeviceCoord2D position;
float distance;
} PEXPDDCHitBox;
typedef struct {
short x;
short y;
} PEXDeviceCoord2D;
typedef struct {
unsigned short length;
char ∗record;
} PEXPickDataRecord;
Errors
BadPEXPathThe specified path is invalid.
BadPEXPickMeasure
The specified pick measure resource identifier is invalid.
See Also
PEXFreePickMeasure