Method: Vips::Image#insert

Defined in:
lib/vips8/methods.rb

#insert(sub, x, y, opts = {}) ⇒ Vips::Image

Insert image @sub into @main at @x, @y.

Parameters:

  • sub (Vips::Image)

    Sub-image to insert into main image

  • x (Integer)

    Left edge of sub in main

  • y (Integer)

    Top edge of sub in main

  • opts (Hash) (defaults to: {})

    Set of options

Options Hash (opts):

  • :expand (Boolean)

    Expand output to hold all of both inputs

  • :background (Array<Double>)

    Colour for new pixels

Returns:

[View source]

# File 'lib/vips8/methods.rb', line 325