I'm trying to find normalised 2D coordinates for a point (Px,Py,Pz) that lies on a planar surface, which is defined by straight lines between 4 points c1-c4 (numbered anticlockwise).
General vector equations
The Attempt at a Solution
Suppose the point c1 is in the bottom left corner. The horizontal lines bounding the top and bottom of the surface are i) from c1 to c2 and ii) from c4 to c3. A normalised x-coordinate creates a pair of points (M,N) that are an equal proportion along both lines. M and N are chosen such that a a line from M to N passes through P. A similar y-coordinate is used to locate the point vertically.
The diagram below shows an example, with (normally unknown) normalised coordinates (0.8,0.5)
to find the normalised coordinates:
Suppose A is the normalised x-coordinate
A line from M to N must have the same unit vector as a line from M to P
and similar for (Ny-My) and (Nz-Mz)
I now have the following problem
i) The equation above does not seem to be able to generate a closed form expression for A
ii) A appears to cancel in the LHS of the equation above (given that 0<A<1, so it can be taken out of the square root). This suggests that the unit vector is independent of the normalised x-coordinate, which doesn't seem to be correct.
Can anybody help with this? or think of a better method?