Re: How to check if an image has an alpha channel?
Re: How to check if an image has an alpha channel?
- Subject: Re: How to check if an image has an alpha channel?
- From: Shaun Wexler <email@hidden>
- Date: Sat, 7 Oct 2006 12:33:15 -0700
On Oct 7, 2006, at 12:17 PM, Tito Ciuro wrote:
Hello,
I'd like to know if a given image has an alpha channel. Is there a
way to know this in Cocoa?
Thanks
NSEnumerator *repEnum = [[aGivenImage representations]
objectEnumerator];
NSImageRep *rep;
while ((rep = [repEnum nextObject]) && ![rep hasAlpha]));
BOOL hasAlpha = rep != nil;
--
Shaun Wexler
MacFOH
http://www.macfoh.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden