fixed rotated rectangle (center instead of corner)
Merge pull request #2396 from m3d:patch-1