Re: Applying a transparent color over an image
Re: Applying a transparent color over an image
- Subject: Re: Applying a transparent color over an image
- From: "John C. Randolph" <email@hidden>
- Date: Fri, 15 Apr 2005 17:53:16 -0700
On Apr 14, 2005, at 1:23 AM, Duncan Campbell wrote:
Hey folks.
I've developed my own custom tabs (for an editor I'm building). My
tabs (NSView subclasses) have 3 images: 1 for unselected, 1 for
mouse-over (using a tracking-rect) and 1 for selected.
Since the 3 images are the same - just different colors - I was
thinking it would likely be much more efficient to simple apply
some kind of alpha-color transparency over the base unselected
image (Note the images are not solid colors - so using something
like [colorWithCalibratedWhite:] isn't going to work).
I guess I'm looking for something like: [imageWithCalibratedWhite:
alpha:] or similar...
Can anyone suggest a way of doing this?
http://developer.apple.com/samplecode/Tinted_Image/Tinted_Image.html
-jcr
John C. Randolph <email@hidden> (408) 974-8819
Sr. Cocoa Software Engineer,
Apple Worldwide Developer Relations
http://developer.apple.com/cocoa/index.html
_______________________________________________
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