cocos2d/cocos2d-iphone — pull request #247 by slembcke (2012-10-15 19:45:53+00:00)
Title: Respect custom projections when converting coordinates.

I use custom projections in all of my universal Cocos2D projects so I can set an iPad resolution of 512x384. That along with a terrible hack so it runs with a content scale of 2x on the iPad (4x on retina iPad), it makes the iPad versions a lot easier to manage. They are pretty close to retina iPhone size, just a little bit bigger. Makes it much easier to share code and content between the two versions as the sizing all stays the same.

Anyway I won't share the terrible, fragile content scale hack, but one of the issues with using a custom projection is that the CCDirector methods don't know how to convert coordinates for them. It just does a simple flip assuming that GL coords are just flipped and calls it good. I fixed them to use the projection matrix instead.