In your 3D model, you have two Z values (for depth). Z-near (the 'location' of your screen) and Z-far (the furthest z-plane of your 3D model). The user touches the screen and Xs, Ys.
Now call gluUnProject twice: gluUnProject(xWin, ((float)screenH)-yWin, *zNear*, modelMatrix, 0, projMatrix, 0, mView, 0, *outputCoordsNear*, 0); gluUnProject(xWin, ((float)screenH)-yWin, *zFar*, modelMatrix, 0, projMatrix, 0, mView, 0, *outputCoordsFar*, 0); Now you have a *line *in your 3D model that starts at your screen 'outputCoordsNear' and ends at 'outputCoordsFar' Dust off your geometry-class' books and figure out how to move your Square so that (the center of) it will intersect with this line. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

