VOOZH about

URL: https://www.geeksforgeeks.org/python/wand-composite-function-in-python/

⇱ Wand composite() function in Python - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Wand composite() function in Python

Last Updated : 11 May, 2020
The composite() function renders an image on top of the drawing subject image using COMPOSITE_OPERATORS. A compositing image must be given with a destination top, left, width, and height values.
Syntax: wand.drawing.composite(image, left, top, operator, arguments, gravity) Parameters :
Parameter Input Type Description
image wand.image.Image the image placed over the current image
left numbers.Integral the x-coordinate where image will be placed
top numbers.Integral the y-coordinate where image will be placed
operator basestring the operator that affects how the composite is applied to the image.
arguments basestring Additional numbers given as a geometry string, or comma delimited values. This is needed for 'blend', 'displace', 'dissolve', and 'modulate' operators.
gravity basestring Calculate the top & left values based on gravity value from GRAVITY_TYPES.
The following is the list of COMPOSITE_OPERATORS :
('undefined', 'alpha', 'atop', 'blend', 'blur', 'bumpmap', 'change_mask', 'clear', 'color_burn', 'color_dodge', 'colorize', 'copy_black', 'copy_blue', 'copy', 'copy_cyan', 'copy_green', 'copy_magenta', 'copy_alpha', 'copy_red', 'copy_yellow', 'darken', 'darken_intensity', 'difference', 'displace', 'dissolve', 'distort', 'divide_dst', 'divide_src', 'dst_atop', 'dst', 'dst_in', 'dst_out', 'dst_over', 'exclusion', 'hard_light', 'hard_mix', 'hue', 'in', 'intensity', 'lighten', 'lighten_intensity', 'linear_burn', 'linear_dodge', 'linear_light', 'luminize', 'mathematics', 'minus_dst', 'minus_src', 'modulate', 'modulus_add', 'modulus_subtract', 'multiply', 'no', 'out', 'over', 'overlay', 'pegtop_light', 'pin_light', 'plus', 'replace', 'saturate', 'screen', 'soft_light', 'src_atop', 'src', 'src_in', 'src_out', 'src_over', 'threshold', 'vivid_light', 'xor', 'stereo')
Input Images: Image #1: 👁 Image
Image #2: 👁 Image
Example #1: Output : 👁 Image
Example #1:
Output: 👁 Image
Comment
Article Tags: