Sha256: be5530374528dfe566211931e942349b9638858b9d6014207506e1381a27dee3

Contents?: true

Size: 279 Bytes

Versions: 29

Compression:

Stored size: 279 Bytes

Contents

#! /usr/local/bin/ruby -w
require 'RMagick'

# Demonstrate the Image#threshold method

img = Magick::Image.read('images/Flower_Hat.jpg').first

# Use a threshold of 55% of QuantumRange.
img = img.threshold(Magick::QuantumRange*0.55)

#img.display
img.write('threshold.jpg')
exit

Version data entries

29 entries across 29 versions & 2 rubygems

Version Path
rmagick-2.13.4 doc/ex/threshold.rb
rmagick-2.13.3 doc/ex/threshold.rb
rmagick-2.13.3.rc1 doc/ex/threshold.rb
rmagick-2.13.2 doc/ex/threshold.rb
rdp-rmagick-0.0.0 doc/ex/threshold.rb
rmagick-2.13.1 doc/ex/threshold.rb
rmagick-2.12.2 doc/ex/threshold.rb
rmagick-2.12.1 doc/ex/threshold.rb
rmagick-2.12.0 doc/ex/threshold.rb
rmagick-2.11.1 doc/ex/threshold.rb
rmagick-2.10.0 doc/ex/threshold.rb
rmagick-2.11.0 doc/ex/threshold.rb
rmagick-2.2.0 doc/ex/threshold.rb
rmagick-2.0.0 doc/ex/threshold.rb
rmagick-2.1.0 doc/ex/threshold.rb
rmagick-2.2.2 doc/ex/threshold.rb
rmagick-2.3.0 doc/ex/threshold.rb
rmagick-2.4.0 doc/ex/threshold.rb
rmagick-2.5.0 doc/ex/threshold.rb
rmagick-2.5.1 doc/ex/threshold.rb