Sha256: 847c86000aa88f3a6b603f5825b5251e7219e45e16b43742c88476286e23b4aa

Contents?: true

Size: 316 Bytes

Versions: 29

Compression:

Stored size: 316 Bytes

Contents

#!/usr/local/bin/ruby -w

# Demonstrate the random_channel_threshold method

require 'RMagick'

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

geom = Magick::Geometry.new(Magick::QuantumRange/2)
img2 = img.random_threshold_channel(geom, Magick::RedChannel)

img2.write('random_threshold_channel.jpg')
exit

Version data entries

29 entries across 29 versions & 2 rubygems

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