I played with a paper application on Facebook and realized that the parallax effect on a full-size image is very cool. So I went to try it in my application. but parallax did not move as smoothly as the facebook paper app.
here is the code i used
UIInterpolatingMotionEffect *parallaxHorizontal = [[UIInterpolatingMotionEffect alloc]initWithKeyPath:@"center.x" type:UIInterpolatingMotionEffectTypeTiltAlongHorizontalAxis]; parallaxHorizontal.minimumRelativeValue = @-100.0; parallaxHorizontal.maximumRelativeValue = @100.0; [_myImageView addMotionEffect:interpolationHorizontal];
itβs all the same for parallax to move a little faster and smoother, or to achieve as a facebook paper application.
Thanks!
source share