Class: Imatcher::Modes::Delta
Overview
Compare pixels using Delta E distance.
Instance Attribute Summary collapse
-
#tolerance ⇒ Object
readonly
Returns the value of attribute tolerance.
Attributes inherited from Base
#bounds, #exclude_rect, #include_rect, #result, #threshold
Instance Method Summary collapse
-
#initialize(options) ⇒ Delta
constructor
A new instance of Delta.
Methods inherited from Base
#area, #compare, #diff, #update_bounds
Methods included from ColorMethods
#blue, #brightness, #green, #red
Constructor Details
#initialize(options) ⇒ Delta
Returns a new instance of Delta.
9 10 11 12 13 |
# File 'lib/imatcher/modes/delta.rb', line 9 def initialize() @tolerance = .delete(:tolerance) || 0.01 @delta_score = 0.0 super() end |
Instance Attribute Details
#tolerance ⇒ Object (readonly)
Returns the value of attribute tolerance.
7 8 9 |
# File 'lib/imatcher/modes/delta.rb', line 7 def tolerance @tolerance end |