如何从UIImage(Cocoa Touch)或CGImage(核心图形)获取像素数据?
- (int)getRGBAFromImage:(UIImage *)image atX:(int)xx andY:(int)yy {
// [...]
// What do I want to read about to help
// me fill in this bit, here?
// [...]
int result = (red << 24) | (green << 16) | (blue << 8) | alpha;
return result;}
森林海
ABOUTYOU
随时随地看视频慕课网APP