CGImageRef 내부의 CGPoint
-
09-12-2019 - |
문제
혹시 알 수 있나요? CGPoint
안에 있다 CGImageRef
?아니면 전환해야겠어요 CGImageRef
다른 형식으로?
업데이트
maskcontext = CGBitmapContextCreate(currentM, w,
h,
bitsPerComponent, bytesPerRow, colorSpace,
kCGImageAlphaNone);
maskImage = CGBitmapContextCreateImage(maskcontext);
어디 currentM
이다 unsigned char
, maskcontext
는 CGContextRef
그리고 maskImage
는 CGImageRef
그리고 나는 그것이 알고 싶다 rect
.
해결책
이미지의 프레임을 얻을 수 있나요?그러면 다음을 수행할 수 있습니다.
CGRectContainsPoint ( CGRect rect, CGPoint point )
해당 지점이 해당 프레임 안에 있는지 확인합니다.
제휴하지 않습니다 StackOverflow