在NSImage class reference據說存在方法initWithData
,但爲什麼xCode說它不存在?NSImage initWithData未找到?
我用這樣的:
NSData *imgData = [[imageView image] TIFFRepresentation];
fotoImg = [NSImage initWithData:imgData];
,我也得到警告:
Class method '+initWithData:' not found (return type defaults to 'id')
這究竟是爲什麼?
'[[NSImage alloc] initWithData..' – 2012-07-09 13:32:31