I asked an old professor for help on transforming screen coordinates into worldspace coordinates, and his solution was for me to put four objects on the world with known positions and print their screen coordinates, then do the following. The first numbers are my results (worldspace, then screen), and the last description was his response to me. I just got two books on matrices off Amazon but they haven't arrived yet and I don't remember a lot about matrices, so I need help from someone who does.

-300, -300, 0.008033752

300, -300, 0.008033752

300, 300, 0.008033752

-300, 300, 0.008033752

Screen coordinates: 209, 180

Screen coordinates: 594, 180

Screen coordinates: 595, 563

Screen coordinates: 210, 564

After getting those values I would have the following matrices.

M(P1) => S1

M(P2) => S2

M(P3) => S3

M(P4) =>S4

Where Pi is the position (in the world) of the 4 objects. This is known.

Si is the position (on the screen) of the 4 objects. Also known - via

the print function.

Those equations will be enough to compute the map functions you need -

particularly from your view. Just solve the equations by hand or use

the following observation.

Let P be the matrix formed with P1 P2 P3 P4 (as columns).

The same for S.

Then the above becomes

MP = S

Multiply both sides by the inverse of P (assuming it is non-singular) -

actually if done right might only need 3 objects.

MP P^-1 = S P^-1

Which becomes

M = S P^-1

Actually you want the inverse of M (to reverse the process). But this

is then:

M^-1 = P S^-1

That is compute S inverse and multiply with P to get the inverse matrix.

Then for any screen point S_i you would be able to do M S_i and get P_i.