Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
CALayer のコンテンツの一部のみを表示する方法はありますか? contentRect; を使用してみました。ただし、必要に応じて機能するかどうかはよくわかりません。画像があり、ユーザーが指をドラッグして画像の一部を表示するだけでよいとします。contentRectは行くべき道ですか?
boundsプロパティを使用する必要があります
bounds
imageView.layer.bounds = CGRectMake(20, 20, 200, 200);