Sha256: 1806537be532ca935dc1e15fff1932fbe7207b89b096d0e9de23d6f69659e6bd

Contents?: true

Size: 316 Bytes

Versions: 6

Compression:

Stored size: 316 Bytes

Contents

#!/usr/bin/env 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

6 entries across 6 versions & 1 rubygems

Version Path
rmagick-4.1.0.rc2 doc/ex/random_threshold_channel.rb
rmagick-4.1.0.rc1 doc/ex/random_threshold_channel.rb
rmagick-4.0.0 doc/ex/random_threshold_channel.rb
rmagick-3.2.0 doc/ex/random_threshold_channel.rb
rmagick-3.1.0 doc/ex/random_threshold_channel.rb
rmagick-3.0.0 doc/ex/random_threshold_channel.rb