I’m testing the response time differences between the native accelerometer method and the cocos2d udpate method (which is every frame, or 60 times a second if using the maximum frame rate) where update takes variable information that is updated in accelerometer.
Of course, when moving sprites across the screen using just the accelerometer method, they are not smooth and even if the sprite’s position is calculated the same with the acceleration response in either accelerometer and update the accelerometer method clearly doesn’t update as often as the sprite moves much more slowly across the screen.
I’m guessing this is because iOS does not natively update the UIAccelerometer anywhere near 60 times a second, so does anyone know where I can find out how often it does?
its up to you.
the
UIAccelerometerobject hasUpdateintervalproperty that you definedhow many times the accelerometer will update.
Ex:
which mean 30 times per one seconed.
it can take up to 60.