Method: Magick::Image#scale

Defined in:
ext/RMagick/rmimage.cpp

#scale(scale) ⇒ Magick::Image #scale(cols, rows) ⇒ Magick::Image

Change the size of an image to the given dimensions. Alias of #sample.

Overloads:

  • #scale(scale) ⇒ Magick::Image

    Parameters:

    • scale (Float)

      You can use this argument instead of specifying the desired width and height. The percentage size change. For example, 1.25 makes the new image 125% of the size of the receiver. The scale factor 0.5 makes the new image 50% of the size of the receiver.

  • #scale(cols, rows) ⇒ Magick::Image

    Parameters:

    • cols (Numeric)

      The desired width.

    • rows (Numeric)

      The desired height.

Returns:

See Also:



12455
12456
12457
12458
12459
12460
# File 'ext/RMagick/rmimage.cpp', line 12455

VALUE
Image_scale(int argc, VALUE *argv, VALUE self)
{
    rm_check_destroyed(self);
    return scale(False, argc, argv, self, GVL_FUNC(ScaleImage));
}