#include <nnsys/g3d/util.h> int NNS_G3dLocalOriginToScrPos( int* px , int* py );
| px | Pointer to the x coordinate on the screen |
| py | Pointer to the y coordinate on the screen |
Returns 0 if *px and *py are inside the viewport. Returns -1 if they are outside of the viewport.
Looks for the position of the local coordinate origin on the screen. The current position matrix and the current projection matrix must be appropriately configured. Even if the return value is -1, the value is stored in *px and *py can be used as a directional guide. When applying a horizontal offset to the 3D screen by using the Nitro-SDK G3X_SetHOffset function, only the offset portion of the obtained x coordinate needs to be moved.
NNS_G3dWorldPosToScrPos, NNS_G3dScrPosToWorldLine
11/01/2004 Initial version.