Layer.operateRect

Function/Meaning

Rectangle arithmetic composition

Type
Layerclassmethod of
Syntax
operateRect(dleft, dtop, src, sleft, stop, swidth, sheight, mode=omAuto, opa=255)
Arguments
dleft

Specifies the left edge position of the calculation destination rectangle in pixels (at the image position of the calculation destination layer).

dtop

Specifies the top position of the calculation destination rectangle in pixels (at the image position of the calculation destination layer).

src

Specify the layer object from which the operation is performed.
You can also specify an object of the Bitmap class.

sleft

Specifies the left edge position of the rectangle to be calculated, in pixels (at the image position of the calculation source layer).

stop

Specifies the top position of the rectangle to be calculated, in pixels (at the image position of the calculation source layer).

swidth

Specifies the width of the rectangle to be calculated, in pixels (at the image position of the calculation source layer).

sheight

Specifies the vertical width of the rectangle to be calculated, in pixels (at the image position of the calculation source layer).

mode

Specifies the operation mode.

  • If omAuto is specified, the operation type is automatically determined according to the Layer.type property of the operation source layer.
  • If omPsNormal is specified, Photoshop compatible alpha compositing is done.
  • If omPsAdditive is specified, Photoshop compatible dodging (linear) compositing is done.
  • If omPsSubtractive is specified, Photoshop compatible burn (linear) compositing is performed.
  • If omPsMultiplicative is specified, Photoshop compatible multiplication and composition will be performed.
  • If omPsScreen is specified, Photoshop compatible screen composition will be performed.
  • If omPsOverlay is specified, Photoshop compatible overlay compositing is done.
  • If omPsHardLight is specified, Photoshop compatible hard light composition will be performed.
  • If omPsSoftLight is specified, Photoshop compatible softlight compositing will be performed.
  • If omPsColorDodge is specified, Photoshop compatible dodge color composition will be performed.
  • If omPsColorDodge5 is specified, dodge color composition compatible with Photoshop version 5.x and below will be performed.
  • If omPsColorBurn is specified, Photoshop compatible burn-in color composition will be performed.
  • If omPsLighten is specified, Photoshop compatible comparison (bright) compositing is performed.
  • If omPsDarken is specified, Photoshop compatible comparison (dark) compositing is done.
  • If omPsDifference is specified, Photoshop compatible absolute difference composition is performed.
  • If omPsDifference5 is specified, absolute value composition of the difference compatible with Photoshop version 5.x and below is performed.
  • If omPsExclusion is specified, Photoshop compatible exclusion composition is performed.
  • If omAdditive is specified, additive synthesis is performed.
  • If omSubtractive is specified, subtractive synthesis will be performed.
  • If omMultiplicative is specified, multiplication synthesis is performed.
  • If omDodge is specified, dodging synthesis will be performed.
  • If omDarken is specified, comparative (dark) compositing is done.
  • If omLighten is specified, comparison (bright) composition will be performed.
  • If omScreen is specified, screen multiplication composition is performed.
  • If omAlpha is specified, alpha synthesis will occur.
  • If omAddAlpha is specified, additive alpha composition is done.
  • If omOpaque is specified, the alpha information in src is ignored and src is always considered completely opaque.
opa

Specifies the intensity of the operation (0 to 255).

Return value
None (void)
Explanation

Computes the rectangular part of the specified calculation source layer at the specified position of your layer in the specified mode.
The value of the Layer.face property of the calculation destination layer (which executes the method) and the calculation source layer is ignored.
If omAuto is specified for mode, the operation type is automatically determined according to the Layer.type property of the operation source layer.