Get location in scene for pixel?
There are utility functions to convert 2d region coordinates to 3d:

bpy_extras.view3d_utils

There's also a method to cast a ray in the scene:

Scene.ray_cast

... but it might not work with orthographic view.