math - Convert Cartesian point to point on rotated plane (pic) -


i have cartesian point being given (blue line), , need convert point relative rotated plane (green box). plane rotated @ 28.227º shown below.

sadly, lack of math education has me baffled how solve this. need able take x,y point , convert rotated plane.

any @ on appreciated @ total loss.

best can figure out, need several different calculations depending on input point is.

http://adam-meyer.com/lab/rotatedplane2.png

i love friends know math. kj! here answer.

function convertpoint(x,y){      var degree = -28.227;     var offset = 0; //change if corner not 0,0      x2 = x *math.cos(radians(degree)) + (y - offset) *math.sin(radians(degree));     y2 = x *math.sin(radians(degree)) - (y - offset) *math.cos(radians(degree));      return {x: x2, y: y2} }  function radians(degrees){     return degrees * (math.pi / 180); } 

Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -