Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/iphone/35.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Iphone 在另一个UIImageView上注册UIImageView_Iphone_Objective C_Ios_Xcode_Uiimageview - Fatal编程技术网

Iphone 在另一个UIImageView上注册UIImageView

Iphone 在另一个UIImageView上注册UIImageView,iphone,objective-c,ios,xcode,uiimageview,Iphone,Objective C,Ios,Xcode,Uiimageview,我现在可以在我的应用程序上移动图像、缩放图像、捏图像。。你说吧。但我的问题是,当一个UIImageView位于另一个UIImageView时,如何使应用程序能够注册?您可能希望查看 具体来说,您应该查看CGRectIntersectsRect,查看两个UIImageView的帧是否相交 BOOL isImageViewOverlapping = CGRectIntersectsRect(imageViewOne.frame, imageViewTwo.frame); 在另一个UIImageVi

我现在可以在我的应用程序上移动图像、缩放图像、捏图像。。你说吧。但我的问题是,当一个UIImageView位于另一个UIImageView时,如何使应用程序能够注册?

您可能希望查看

具体来说,您应该查看
CGRectIntersectsRect
,查看两个
UIImageView
的帧是否相交

BOOL isImageViewOverlapping = CGRectIntersectsRect(imageViewOne.frame, imageViewTwo.frame);

在另一个UIImageView中,您所说的
是什么意思?
。你是说交叉?谢谢!这就是我需要的:)