How do you make an NSImage Image have rounded corners? I'm doing Mac Dev not iPhone de开发者_运维百科v.
Thanks in advance.
If you mean you want to draw a square image cropped to a rounded rectangle, take a look at NSBezierPath's clipping functions. Just clip to the frame you want and draw.
Make the corners of a regular rectangular NSImage transparent. You can do that by ANDing the alpha channel of the bitmap or image with an appropriate round-rect mask or mask image.
精彩评论