Setting the origin to center of the screen instead of the top left screen?(iPhone)

Posted by thyrgle on Stack Overflow See other posts from Stack Overflow or by thyrgle
Published on 2010-05-18T02:11:40Z Indexed on 2010/05/18 2:20 UTC
Read the original article Hit count: 269

Filed under:
|

Hi, I am working on an iPhone app and I am trying to make something that has to do with line-circle collision detection. I am using the slope of the line and checking if the coordinates of a circle suffice the equation y = mx + b. But, with the current origin (0,0) at the top left it is a pain to get the slope. Any way I can convert the coordinates so the origin is in the center of the screen?

© Stack Overflow or respective owner

Related posts about iphone

Related posts about coordinates