lib/vips/methods.rb in ruby-vips-1.0.4 vs lib/vips/methods.rb in ruby-vips-1.0.5

- old
+ new

@@ -115,34 +115,34 @@ # Perform a round function on an image. # @param round [Vips::OperationRound] rounding operation to perform # @param [Hash] opts Set of options # @return [Vips::Image] Output image -# @!method relational_const(c, relational, opts = {}) +# @!method relational_const(relational, c, opts = {}) # Relational operations against a constant. -# @param c [Array<Double>] Array of constants # @param relational [Vips::OperationRelational] relational to perform +# @param c [Array<Double>] Array of constants # @param [Hash] opts Set of options # @return [Vips::Image] Output image # @!method remainder_const(c, opts = {}) # Remainder after integer division of an image and a constant. # @param c [Array<Double>] Array of constants # @param [Hash] opts Set of options # @return [Vips::Image] Output image -# @!method boolean_const(c, boolean, opts = {}) +# @!method boolean_const(boolean, c, opts = {}) # Boolean operations against a constant. -# @param c [Array<Double>] Array of constants # @param boolean [Vips::OperationBoolean] boolean to perform +# @param c [Array<Double>] Array of constants # @param [Hash] opts Set of options # @return [Vips::Image] Output image -# @!method math2_const(c, math2, opts = {}) +# @!method math2_const(math2, c, opts = {}) # Binary math operations with a constant. -# @param c [Array<Double>] Array of constants # @param math2 [Vips::OperationMath2] math to perform +# @param c [Array<Double>] Array of constants # @param [Hash] opts Set of options # @return [Vips::Image] Output image # @!method complex(cmplx, opts = {}) # Perform a complex operation on an image. @@ -290,13 +290,11 @@ # @return [Vips::Image] Output image # @!method sequential(opts = {}) # Check sequential access. # @param [Hash] opts Set of options -# @option opts [Boolean] :trace trace pixel requests # @option opts [Integer] :tile_height Tile height in pixels -# @option opts [Vips::Access] :access Expected access pattern # @return [Vips::Image] Output image # @!method cache(opts = {}) # Cache an image. # @param [Hash] opts Set of options @@ -311,11 +309,11 @@ # @param y [Integer] Top edge of input in output # @param width [Integer] Image width in pixels # @param height [Integer] Image height in pixels # @param [Hash] opts Set of options # @option opts [Vips::Extend] :extend How to generate the extra pixels -# @option opts [Array<Double>] :background Colour for background pixels +# @option opts [Array<Double>] :background Color for background pixels # @return [Vips::Image] Output image # @!method flip(direction, opts = {}) # Flip an image. # @param direction [Vips::Direction] Direction to flip image @@ -327,22 +325,22 @@ # @param sub [Vips::Image] Sub-image to insert into main image # @param x [Integer] Left edge of sub in main # @param y [Integer] Top edge of sub in main # @param [Hash] opts Set of options # @option opts [Boolean] :expand Expand output to hold all of both inputs -# @option opts [Array<Double>] :background Colour for new pixels +# @option opts [Array<Double>] :background Color for new pixels # @return [Vips::Image] Output image # @!method join(in2, direction, opts = {}) # Join a pair of images. # @param in2 [Vips::Image] Second input image # @param direction [Vips::Direction] Join left-right or up-down # @param [Hash] opts Set of options -# @option opts [Vips::Align] :align Align on the low, centre or high coordinate edge # @option opts [Boolean] :expand Expand output to hold all of both inputs # @option opts [Integer] :shim Pixels between images # @option opts [Array<Double>] :background Colour for new pixels +# @option opts [Vips::Align] :align Align on the low, centre or high coordinate edge # @return [Vips::Image] Output image # @!method self.arrayjoin(in, opts = {}) # Join an array of images. # @param in [Array<Image>] Array of input images @@ -372,10 +370,18 @@ # @param width [Integer] Width of extract area # @param height [Integer] Height of extract area # @param [Hash] opts Set of options # @return [Vips::Image] Output image +# @!method smartcrop(width, height, opts = {}) +# Extract an area from an image. +# @param width [Integer] Width of extract area +# @param height [Integer] Height of extract area +# @param [Hash] opts Set of options +# @option opts [Vips::Interesting] :interesting How to measure interestingness +# @return [Vips::Image] Output image + # @!method extract_band(band, opts = {}) # Extract band from an image. # @param band [Integer] Band to extract # @param [Hash] opts Set of options # @option opts [Integer] :n Number of bands to extract @@ -1404,11 +1410,11 @@ # @param width [Integer] Size to this width # @param [Hash] opts Set of options # @option opts [Integer] :height Size to this height # @option opts [Vips::Size] :size Only upsize, only downsize, or both # @option opts [Boolean] :auto_rotate Use orientation tags to rotate image upright -# @option opts [Boolean] :crop Reduce to fill target rectangle, then crop +# @option opts [Vips::Interesting] :crop Reduce to fill target rectangle, then crop # @option opts [Boolean] :linear Reduce in linear light # @option opts [String] :import_profile Fallback import profile # @option opts [String] :export_profile Fallback export profile # @return [Vips::Image] Output image @@ -1418,11 +1424,11 @@ # @param width [Integer] Size to this width # @param [Hash] opts Set of options # @option opts [Integer] :height Size to this height # @option opts [Vips::Size] :size Only upsize, only downsize, or both # @option opts [Boolean] :auto_rotate Use orientation tags to rotate image upright -# @option opts [Boolean] :crop Reduce to fill target rectangle, then crop +# @option opts [Vips::Interesting] :crop Reduce to fill target rectangle, then crop # @option opts [Boolean] :linear Reduce in linear light # @option opts [String] :import_profile Fallback import profile # @option opts [String] :export_profile Fallback export profile # @return [Vips::Image] Output image @@ -1525,11 +1531,11 @@ # @return [Vips::Image] Output image # @!method Lab2XYZ(opts = {}) # Transform cielab to xyz. # @param [Hash] opts Set of options -# @option opts [Array<Double>] :temp Colour temperature +# @option opts [Array<Double>] :temp Color temperature # @return [Vips::Image] Output image # @!method XYZ2Lab(opts = {}) # Transform xyz to lab. # @param [Hash] opts Set of options @@ -1907,50 +1913,50 @@ # @option opts [Integer] :segments Output Number of discrete contigious regions # @return [Vips::Image, Hash<Symbol => Object>] Mask of region labels, Hash of optional output items # @!method draw_rect(ink, left, top, width, height, opts = {}) # Paint a rectangle on an image. -# @param ink [Array<Double>] Colour for pixels +# @param ink [Array<Double>] Color for pixels # @param left [Integer] Rect to fill # @param top [Integer] Rect to fill # @param width [Integer] Rect to fill # @param height [Integer] Rect to fill # @param [Hash] opts Set of options # @option opts [Boolean] :fill Draw a solid object # @return [Vips::Image] Image to draw on # @!method draw_mask(ink, mask, x, y, opts = {}) # Draw a mask on an image. -# @param ink [Array<Double>] Colour for pixels +# @param ink [Array<Double>] Color for pixels # @param mask [Vips::Image] Mask of pixels to draw # @param x [Integer] Draw mask here # @param y [Integer] Draw mask here # @param [Hash] opts Set of options # @return [Vips::Image] Image to draw on # @!method draw_line(ink, x1, y1, x2, y2, opts = {}) # Draw a line on an image. -# @param ink [Array<Double>] Colour for pixels +# @param ink [Array<Double>] Color for pixels # @param x1 [Integer] Start of draw_line # @param y1 [Integer] Start of draw_line # @param x2 [Integer] End of draw_line # @param y2 [Integer] End of draw_line # @param [Hash] opts Set of options # @return [Vips::Image] Image to draw on # @!method draw_circle(ink, cx, cy, radius, opts = {}) # Draw a circle on an image. -# @param ink [Array<Double>] Colour for pixels +# @param ink [Array<Double>] Color for pixels # @param cx [Integer] Centre of draw_circle # @param cy [Integer] Centre of draw_circle # @param radius [Integer] Radius in pixels # @param [Hash] opts Set of options # @option opts [Boolean] :fill Draw a solid object # @return [Vips::Image] Image to draw on # @!method draw_flood(ink, x, y, opts = {}) # Flood-fill an area. -# @param ink [Array<Double>] Colour for pixels +# @param ink [Array<Double>] Color for pixels # @param x [Integer] DrawFlood start point # @param y [Integer] DrawFlood start point # @param [Hash] opts Set of options # @option opts [Vips::Image] :test Test pixels in this image # @option opts [Boolean] :equal DrawFlood while equal to edge