Skip to content
Browse files

Drop frame rate & don't set motion manager to 'nil' on stop method

  • Loading branch information...
1 parent cc33d88 commit cae80dfde515b98fcd38cd5865bd1215ac552c4c @thisandagain committed
Showing with 2 additions and 3 deletions.
  1. +2 −3 DIYParallax/DIYParallax.m
View
5 DIYParallax/DIYParallax.m
@@ -10,7 +10,7 @@
//
-#define UPDATE_INTERVAL 1.0f/90
+#define UPDATE_INTERVAL 1.0f/40
#define OFFSET_MULTIPLIER 60.0f
//
@@ -117,7 +117,6 @@ - (void)stopListening
{
[motionManager stopDeviceMotionUpdates];
}
- motionManager = nil;
}
#pragma mark - Private methods
@@ -154,7 +153,7 @@ - (void)update:(CGPoint)point
*
* @return CGFloat
*/
-- (double)calculateTransformForAngle:(double)angle withDistance:(double)distance
+- (CGFloat)calculateTransformForAngle:(CGFloat)angle withDistance:(CGFloat)distance
{
return angle * distance;
}

0 comments on commit cae80df

Please sign in to comment.
Something went wrong with that request. Please try again.