Sha256: 038b54be53af90e6b6a6929f735ab75fa4e22f0cb4f9ec09e7cf7ac1d80c4d2b
Contents?: true
Size: 494 Bytes
Versions: 5
Compression:
Stored size: 494 Bytes
Contents
$LOAD_PATH.unshift('lib') require 'spyglass' include Spyglass window = GUI::Window.new "Original" apple = Image.load File.expand_path('images/apple.jpg', File.dirname(__FILE__)) window.show(apple) canny = apple.convert(ColorSpace[:BGR => :Gray]) canny.canny!(200, 300) result = Image.new result.copy!(apple) result.draw_contours(canny.contours, Color.new(255, 0, 0)) result_window = GUI::Window.new "Contours" result_window.show(result) loop do break if GUI::wait_key(10) > 0 end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
spyglass-0.0.5.1 | examples/contours.rb |
spyglass-0.0.5 | examples/contours.rb |
spyglass-0.0.4.1 | examples/contours.rb |
spyglass-0.0.4 | examples/contours.rb |
spyglass-0.0.3 | examples/contours.rb |