The function works just fine returning the world coordinates.
However, I’d like to identify the actual point relative to the terrain, so that later I can, for example, put a tree on that specific point.
I suppose I have to take into account camera transformations and rotations, but I don’t know how.
Thanks for the answer and sorry for my ignorance on this matter. So you say that even if I rotate or translate the terrain, the values should always be the same ?
My aim would be to gather the “local” point clicked on the terrain. So even if I rotate the camera, translate the terrain, if I click on the center of the terrain (regular quad grid ranging between -4,+4) it should always give 0,0, and -4->4 values at the corners.
As for now, I only get correct values if the camera is not moved.
Any idea ?