Expand Minimize

CopyPixelOperation Enumeration

Determines how the source color in a copy pixel operation is combined with the destination color to result in a final color.

Namespace:  System.Drawing
Assembly:  System.Drawing (in System.Drawing.dll)

[ComVisibleAttribute(true)]
public enum CopyPixelOperation

Member nameDescription
BlacknessThe destination area is filled by using the color associated with index 0 in the physical palette. (This color is black for the default physical palette.)
CaptureBltWindows that are layered on top of your window are included in the resulting image. By default, the image contains only your window. Note that this generally cannot be used for printing device contexts.
DestinationInvertThe destination area is inverted.
MergeCopyThe colors of the source area are merged with the colors of the selected brush of the destination device context using the Boolean AND operator.
MergePaintThe colors of the inverted source area are merged with the colors of the destination area by using the Boolean OR operator.
NoMirrorBitmapThe bitmap is not mirrored.
NotSourceCopyThe inverted source area is copied to the destination.
NotSourceEraseThe source and destination colors are combined using the Boolean OR operator, and then resultant color is then inverted.
PatCopyThe brush currently selected in the destination device context is copied to the destination bitmap.
PatInvertThe colors of the brush currently selected in the destination device context are combined with the colors of the destination are using the Boolean XOR operator.
PatPaintThe colors of the brush currently selected in the destination device context are combined with the colors of the inverted source area using the Boolean OR operator. The result of this operation is combined with the colors of the destination area using the Boolean OR operator.
SourceAndThe colors of the source and destination areas are combined using the Boolean AND operator.
SourceCopyThe source area is copied directly to the destination area.
SourceEraseThe inverted colors of the destination area are combined with the colors of the source area using the Boolean AND operator.
SourceInvertThe colors of the source and destination areas are combined using the Boolean XOR operator.
SourcePaintThe colors of the source and destination areas are combined using the Boolean OR operator.
WhitenessThe destination area is filled by using the color associated with index 1 in the physical palette. (This color is white for the default physical palette.)

The CopyPixelOperation enumeration is used by the CopyFromScreen method of the Graphics class.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft