/生成采样对照颜色(黑色)
UIColor* sampleColor = [UIColor colorWithRed:(0/255.0f) green:(0/255.0f) blue:(0/255.0f) alpha:(255/255.0f)];
//比较 if (CGColorEqualToColor(detectedColor.CGColor, sampleColor.CGColor))
{
//处理
}
IOS color 颜色值比较,布布扣,bubuko.com
时间: 2024-11-02 23:20:43