Cicode Programming Reference > Cicode Function Categories > Display Functions Introduction > DspAnGetPos

DspAnGetPos

Gets the x and y coordinates of an AN, in pixels, relative to the top-left corner of the window.

Syntax

DspAnGetPos(AN, X, Y)

AN:

The animation-point number.

X, Y:

The variables used to store the x and y pixel coordinates of the AN, returned from this function.

Return Value

0 (zero) if successful, otherwise an error is returned. The X and Y variables are set to the AN's position if successful, or to -1 if an error has been detected.

Related Functions

DspAnMove, DspAnInRgn, DspGetAnCur, DspGetMouse, DspGetNearestAn

Example

/* Get the position of AN20 into X and Y. /
DspAnGetPos(20,X,Y);

See Also

Display Functions