Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Looking for alpha channel solution for transparencies



I am new to Cocoa, and am looking for a solution to displaying an image that
is partially transparent using an alpha channel.

The Cocoa Mailing List archives show several suggestions regarding use of an
alpha channel in a tiff file and within a custom view in Project Builder.
However, Cocoa does not seem to acknowledge the masked area in a file that
has an alpha channel.

I have experimented with three versions of a tiff file. The first file did
not have an alpha channel, the second one did, and the third had the alpha
channel of the second file inverted. None of these seemed to make a
difference when loaded straight into Interface Builder - they all looked the
same - showing a white background where it should have been transparent.

Next I created a CustomView class in Project Builder where I used some of
the alpha channel methods from the NSColor and NSImage classes with each of
these files. The results were the same for each file, which was a
transparency of the entire image, even the parts that weren't masked as well
and the part that was supposed to be completely transparent was white.

I would appreciate any insights or suggestions.

Thanks!


***********************************
Cynthia Copenhagen
Software Engineer
email@hidden

SoftRAID, LLC

Box 1600
44801 Main Street
Mendocino, CA 95460

phone: 707.937.2280
fax: 707.937.2282

http://www.softraid.com
***********************************




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.