title: How do I detect triangle and rectangle intersection?
body: <p>I am developing an Android game and I would like to know how to detect the collision of a rectangle knowing its position (x and y), width and height and a triangle  knowing x,y, width and height. Triangles are always right triangles as the result of dividing a rectangle through its diagonal so the (x,y) parameter will be a position in the hypotenuse, not the center of the triangle.
  Any help would be appreciated! </p>