I am developing an iP* game and I make use of both UIKit and OpenGL ES 2.0. The UIKit elements are rendered over the OpenGL view and occupy a significant (arbitrary) amount of screen space. I must admit that Apple has done an excellent work and the frame rate of the game is always 60 FPS.
In order to come to this conclusion I made many tests regarding the performance:
- I added lots of static (not moving) UIViews over the OpenGL view -- OK!
- I animated using custom code the same UIViews (modified the center property in the drawFrame method of my game) -- OK!.
- I added many OpenGL ES elements under the UIViews -- OK!
- I added many moving OpenGL ES elements under the UIViews -- OK!
因此,我现在要利用核心评价框架,以便总结国际调查的要素。 我是用的。
[UIView animateWithDuration:delay:options:animations:completion:]
in in perform(I Target 4 or newer)。
现在的问题是,基准率是weird行为: 有时,我有60个缩略语many 许多。 IDKit敏化元素(对我来说,30个元素是OK),而其他一些时候,即使有“single im UIKit元素,但我无法用仪器衡量它! 让我进一步解释: 当我开放仪器并监测核心估计和(或)开放式GL驱动力时,我总是有60个。 But 很明显,情况并非如此,我可以亲眼看到开放式的GL调子,其速度要慢于相应的“IDKit”调子。 如果我从这个观点中删除“科索沃信托公司”要素,该基准率就会恢复正常。 我所描述的类似情况发生在任何开放的利比里亚人经济游戏中,当时用户在玩游戏时改变该装置的数量。 当显示目前数额的透明观点开始消失时,直到完全放弃框架比率急剧下降,但在文书中(我已做过这一检验),它被困在60英尺上!
因此,总而言之:有时,我有60个直径,没有 up子和 down子,有时还有60个直径,没有 up子。
Do you have any solution to this? All tests were performed on an iPad 2 and iPhone 3GS with iOS 5.1