- 発表者:
- 日時:
- 2014.02.23
- 場所:
- ソースコード
UICollectionView + UIKit Dynamics で Force-Directed Layout の実装を試みる
- Force-Directed Layout
- UICollectionView + UIKit Dynamics
- 実装の解説(試作段階)
- 今後の展望
- d3.js
- API Refecence
- Example 1 相当数のデータ表示
- Example 2 クリックでノード追加
- springy.js
- 力学モデル (グラフ描画アルゴリズム) - Wikipedia
- グラフの辺ができるだけ交差しないようにノードを配置
- クーロンの法則 と フックの法則 の組み合わせ
- 206 - Getting Started with UIKit Dynamics
- 221 - Advanced Techniques with UIKit Dynamics
- UIKit Dynamics Catalog ※要developer登録
- Impress Japan: 上を目指すプログラマーのためのiPhoneアプリ開発テクニック iOS 7編 ←おすすめ!!
- UICollectionView + UIKit Dynamics - iOS 7 - objc.io issue #5
- Impress Japan: 上を目指すプログラマーのためのiPhoneアプリ開発テクニック iOS 7編 ←おすすめ!!
- 動作
- UIDynamic Gravity Behavior(重力)
- UIDynamic Collision Behavior(衝突)
- UIDynamic Attachment Behavior(接合)
- UIDynamic Snap Behavior(移動)
- UIDynamic Push Behavior(圧力)
- 設定
- UIDynamic Item Behavior
- d3の force.js を読む
- 高速化の手法の理解も必要(Barnes–Hut simulation, Quadtree, etc...)
- より単純な実装の springy.js を参考に
- 基本的には Wikipediaの実装例 と同等
- C#での実装の解説記事 も参考に
- UIDynamicBehavior のサブクラスを正しく定義
- クーロンの法則 と フックの法則 により作用する力を定義
- クーロンの法則 → UIDynamicPushBehavior
- フックの法則 → UIDynamicAttachmentBehavior
- FDDGraphViewController
- UICollectionViewControllerのサブクラス
- FDDGraphViewNode
- UICollectionViewCellのサブクラス
- FDDForceBehavior
- UIDynamicBehaviorのサブクラス
- FDDForceDirectedLayout
- UICollectionViewLayoutのサブクラス
- ノード間のリンク描画を追加
- Discovrアプリの再現
- d3のデモの再現
- d3のような高速化手法の導入
- 切り出してオープンソースに?