Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
はじめてのKenBurnsEffect
Search
Yoichi Nishimura
February 18, 2015
Technology
1
1.4k
はじめてのKenBurnsEffect
第14回 potatotips (iOS/Android開発Tips共有会) での発表資料
Yoichi Nishimura
February 18, 2015
Tweet
Share
More Decks by Yoichi Nishimura
See All by Yoichi Nishimura
Material Designの作り方 〜Bottom Sheets編〜
nissiy
1
690
iQONのWear Notification最適化
nissiy
2
430
iQON Engineer Seminar - Android
nissiy
0
4.1k
Other Decks in Technology
See All in Technology
非エンジニアにも伝えるメールセキュリティ / Email security for non-engineers
ykanoh
13
4k
AI・LLM事業部のSREとタスクの自動運転
shinyorke
PRO
0
300
Dapr For Java Developers SouJava 25
salaboy
1
130
銀行でDevOpsを進める理由と実践例 / 20250317 Masaki Iwama
shift_evolve
1
110
Multitenant 23ai の全貌 - 機能・設計・実装・運用からマイクロサービスまで
oracle4engineer
PRO
2
120
Restarting_SRE_Road_to_SRENext_.pdf
_awache
0
170
Cloud Native PG 使ってみて気づいたことと最新機能の紹介 - 第52回PostgreSQLアンカンファレンス
seinoyu
2
230
Enterprise AI in 2025?
pamelafox
0
110
技術好きなエンジニアが _リーダーへの進化_ によって得たものと失ったもの / The Gains and Losses of a Tech-Enthusiast Engineer’s “Evolution into Leadership”
kaminashi
0
210
DevinはクラウドエンジニアAIになれるのか!? 実践的なガードレール設計/devin-can-become-a-cloud-engineer-ai-practical-guardrail-design
tomoki10
3
1.4k
Riverpod & Riverpod Generatorを利用して状態管理部分の処理を書き換えてみる簡単な事例紹介
fumiyasac0921
0
110
問題解決に役立つ数理工学
recruitengineers
PRO
8
2.3k
Featured
See All Featured
The MySQL Ecosystem @ GitHub 2015
samlambert
251
12k
Code Review Best Practice
trishagee
67
18k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
Making Projects Easy
brettharned
116
6.1k
BBQ
matthewcrist
88
9.5k
Building Your Own Lightsaber
phodgson
104
6.3k
Adopting Sorbet at Scale
ufuk
75
9.3k
Thoughts on Productivity
jonyablonski
69
4.5k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
60k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
46
2.4k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
4
480
Transcript
͡Ίͯͷ,FO#VSOT&⒎FDU OJTTJZ
"CPVU.F w OJTTJZʢʹͬ͠ʔʣ !ZPJDIJOJTIJNVSB!OJTTJZ w 7"4*-: JOD w J20/࡞͍ͬͯ·͢ w
झຯөըؑ
,FO#VSOT&⒎FDUʁʁʁ
,FO#VSOT&⒎FDU w υΩϡϝϯλϦʔөըͷಜ ,FO#VSOTʢ!LFOCVSOTʣ͕ଟ༻͢Δ ύϯɾνϧτͱζʔϜΛΈ߹Θٕͤͨ๏ w ੩ࢭըʹಈ͖Λ༩͑ΔޮՌ͕͋Γ·͢ w (PPHMF1MBZχϡʔεελϯυͷΞϨ IUUQKBXJLJQFEJBPSHXJLJέϯɾόʔϯζ
,FO#VSOT7JFX࡞Γ·ͨ͠
'SBNF-BZPVUΛܧঝͨ͠$VTUPN7JFX public class KenBurnsView extends FrameLayout { private boolean mDebugLog
= false; private String mDebugTag = “KenBurnsView";
͍͍͢ΠϯλϑΣʔε @InjectView(R.id.ken_burns_effect) KenBurnsView mKenBurnsEffect; private void startKenBurnsEffect(String... urls) { mKenBurnsEffect.setUrls(urls);
} w "DUJWJUZʢ'SBHNFOUʣ͔Β63-PSϦιʔε*%ΛྻͰ͚ͩ͢
͋ͱࣗಈʹΞχϝʔγϣϯ @Override protected void onDetachedFromWindow() { super.onDetachedFromWindow(); mHandler.removeCallbacks(mAnimationRunnable); } w
ը૾ͷಡΈࠐΈ͕ྃͨ͠ΒΞχϝʔγϣϯ։࢝ w PO%FUBDIFE'SPN8JOEPX ͰΞχϝʔγϣϯऴྃ
Ξχϝʔγϣϯ7JFX1SPQFSUZ"OJNBUPSͰ // Ξχϝʔγϣϯͷॳظঢ়ଶϥϯμϜͰੜ͠ɺ͜ͷલͰઃఆ͢Δ ViewPropertyAnimator animator = view.animate() .translationX(toTranslationX) .translationY(toTranslationY) .scaleX(toScale)
.scaleY(toScale) .setDuration(duration); animator.start(); w ը૾αΠζͱཚΛͬͯ4DBMFͱ5SBOTMBUJPOΛܾఆͤ͞Δ w ͦͷใΛͬͯ7JFX1SPQFSUZ"OJNBUPSͰΞχϝʔγϣϯ
̏ ̎ ը૾ͷݟͤํʢ/ͷ߹ʣ ̍ ࣌ؒͷྲྀΕ ̏ ̎ ̍ ̏ ̎
̍ w ֤ͷը૾ͷBMQIBΛ͍ͬͯ͡ը૾͕ೖΕସΘΔΑ͏ʹݟ͍ͤͯΔ
͜ΕͰ,FO#VSOT7JFX͕࡞ΕΔͰʂ εϚϗΞϓϦʹԶͷ໊͕ڹ͖ΔΜʂ
طʹJ20/Ͱ͍ͬͯ·͢ w J20/ͷϒϥϯυϖʔδͰ࣮ w ֤ϒϥϯυͷϞσϧೖΓը૾͔ΒΛදࣔ ࡱΓͷΈͷϒϥϯυਓؾΞΠςϜͰิర
Γ͍ͨ͜ͱ w େ͖͍ը૾͕͞Εͨࡍͷ00.ରࡦΛೖΕΔ w ը૾ͷऔಘॲཧ͕Πέͯͳ͍ͷͰ͢ w Ξχϝʔγϣϯ։࢝ޙʹ63-PSϦιʔε*%Λ ड͚औΕΔΑ͏ʹͯ͠ಈతʹը૾Λࠩ͠ସ͑ΒΕΔΑ͏ʹ͢Δ w ֎෦ϥΠϒϥϦԽͯ͠ެ։
͍͞͝ʹ w εϚϗΞϓϦʹөըͷٕ๏͕ೖ͞Ε͡Ί͍ͯΔ 48:FBSͳͷͰ++"CSBNTͷϨϯζϑϨΞͱ͔དྷΔ͔X w ,FO#VSOT&⒎FDUΧοί͍͍ʂঁͷࢠ͔Βͷධྑ͍ʂ
͋Γ͕ͱ͏͍͟͝·ͨ͠