Using image as a mask
Using image as a mask
- Subject: Using image as a mask
- From: email@hidden
- Date: Tue, 17 Dec 2002 14:04:49 +0000
What compositing action do i need to do to use a black/white tiff as a
mask for what is below it ala alpha Channels.
What im trying to do is set the tint of an image using a color well so
all the black areas in the tiff will gain the selected color when
composited
NSCompositingDestinationIn seems to almost do it but its not quite
working
My testing draw rect method is below
- (void)drawRect:(NSRect)rect
{
[[image backgroundColor] set];
NSRectFill(NSMakeRect(0,0,[image size].width,[image size].height));
[image compositeToPoint:NSZeroPoint operation:compAction];
}
TIA for any help
Warren Burton
**********************************************************************************
This email may contain confidential material. If you were not an
intended recipient, please notify the sender and delete all copies.
We may monitor email to and from our network.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.