Flying Meat
FS • FlySketch: Compositing Modes
Make sure to check out the new wiki located at http://flyingmeat.com/wikka/. This one will eventually be retired.

FlySketch Graphic Compositing Modes

If you are running FlySketch 1.5 on Mac OS X 10.4 or later, you will notice an extra pallet with various "Compositing modes". What the heck are those?

Well, direct from Apple, here's what you get:

  • Clear
    Transparent.
  • Copy
    Source image.
  • Destination Atop
    Destination image wherever both images are opaque, source image wherever source image is opaque but destination image is transparent, and transparent elsewhere.
  • Destination In
    Destination image wherever both images are opaque, and transparent elsewhere.
  • Destination Out
    Destination image wherever destination image is opaque but source image is transparent, and transparent elsewhere.
  • Destination Over
    Destination image wherever destination image is opaque, and source image elsewhere.
  • Plus Darker
    Sum of source and destination images, with color values approaching 0 as a limit.
  • Plus Lighter
    Sum of source and destination images, with color values approaching 1 as a limit.
  • Source Atop
    Source image wherever both images are opaque, destination image wherever destination image is opaque but source image is transparent, and transparent elsewhere.
  • Source In
    Source image wherever both images are opaque, and transparent elsewhere.
  • Source Out
    Source image wherever source image is opaque but destination image is transparent, and transparent elsewhere.
  • Source Over
    Source image wherever source image is opaque, and destination image elsewhere.
  • XOR
    Exclusive OR of source and destination images. Works only with black and white images and is not recommended for color contexts.

Shamelessly stolen from: http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/ObjC_classic/Classes/NSImage.html