문제

혹시 알 수 있나요? CGPoint 안에 있다 CGImageRef?아니면 전환해야겠어요 CGImageRef 다른 형식으로?

업데이트

maskcontext = CGBitmapContextCreate(currentM, w, 
                                               h,
                                               bitsPerComponent, bytesPerRow, colorSpace,
                                               kCGImageAlphaNone);
maskImage = CGBitmapContextCreateImage(maskcontext);

어디 currentM 이다 unsigned char, maskcontextCGContextRef그리고 maskImageCGImageRef 그리고 나는 그것이 알고 싶다 rect.

도움이 되었습니까?

해결책

이미지의 프레임을 얻을 수 있나요?그러면 다음을 수행할 수 있습니다.

CGRectContainsPoint ( CGRect rect, CGPoint point )

해당 지점이 해당 프레임 안에 있는지 확인합니다.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top