Skip to content
プロジェクト

mayuur/MJParallaxCollectionView

GitHubで見る

概要

UICollectionView 内のセルにパララックス効果を追加します。WhatsApp で画像をスクロールしたときや、iOS の Weather アプリをスクロールしたときのような効果が得られます。

デザイン・メディア

この数値の測り方

計測したスター増加

24時間
0
7日間
0
15日間
0
1か月
-1

期間ごとの純増数です。期間は重複しており、日別の値ではありません。未計測の値は空欄です。スター数は注目度の指標であり、品質の保証ではありません。

MJParallaxCollectionView

This is a parallax for the cells inside UICollectionView. It gives us an effect just like scrolling the images in Whatsapp or scrolling through the Weather app for iOS.

Setting it up is really simple.

  1. Just create a NSString array contaning all the names for the images.
  2. Set up the Collection View datasource and delegate methods.
  3. Set the scrollViewDidScroll delegate method for your UICollectionView.
  4. That's it. Now run!

Optionally, you can change the animation speed for the images or the height of the images in the UICollectionViewCell by chnaging the constants used in MJCollectionViewCell.h

Thanks!

Follow me or ask questions or just say Hi! at Twitter : @mayuur

Watch the demo below

Video

Photos from Unsplash

License

Usage is provided under the MIT License. See LICENSE for the full details.

関連プロジェクトを探す

読み込み中…