Class: ReadOnlyImageImpl
- Inherits:
-
Object
- Object
- ReadOnlyImageImpl
- Defined in:
- lib/rimageanalysistools/drawing.rb,
lib/rimageanalysistools/image_shortcuts.rb
Instance Method Summary collapse
- #[](ic) ⇒ Object
-
#box_conservative(lower, upper, dims) ⇒ void
Allows setting a region of interest of an image along only some dimenions, preserving any current region of interest along other dimenions.
Instance Method Details
#[](ic) ⇒ Object
35 36 37 |
# File 'lib/rimageanalysistools/image_shortcuts.rb', line 35 def [](ic) getValue(ic) end |
#box_conservative(lower, upper, dims) ⇒ void
This method returns an undefined value.
Allows setting a region of interest of an image along only some dimenions, preserving any current region of interest along other dimenions.
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
# File 'lib/rimageanalysistools/drawing.rb', line 49 def box_conservative(lower, upper, dims) low_curr = nil up_curr = nil if getIsBoxed then low_curr = getBoxMin up_curr = getBoxMax else low_curr = ImageCoordinate[0,0,0,0,0] up_curr = ImageCoordinate.cloneCoord(getDimensionSizes) end dims.each do |d| low_curr[d]= lower[d] up_curr[d]= upper[d] end end |