Class: OpenCV::Cv::Detail::GraphCutSeamFinder
- Inherits:
-
Object
- Object
- OpenCV::Cv::Detail::GraphCutSeamFinder
- Extended by:
- FFI::DataConverter
- Defined in:
- lib/ropencv/ropencv_types.rb
Class Method Summary collapse
- .new(*args) ⇒ Object
-
.null ⇒ Object
returns a null pointer to the object.
Instance Method Summary collapse
- #cast_to_graph_cut_seam_finder_base(parse_ownership) ⇒ Cv::Detail::GraphCutSeamFinderBase (also: #castToGraphCutSeamFinderBase)
- #cast_to_seam_finder(parse_ownership) ⇒ Cv::Detail::SeamFinder (also: #castToSeamFinder)
-
#find(src, corners, masks) ⇒ Void
methods.
-
#to_s ⇒ Object
converts GraphCutSeamFinder into a string by crawling through all its attributes.
Class Method Details
.new(*args) ⇒ Object
16701 16702 16703 16704 16705 16706 16707 16708 16709 16710 16711 16712 16713 16714 16715 16716 16717 16718 16719 16720 16721 |
# File 'lib/ropencv/ropencv_types.rb', line 16701 def self.new(*args) if args.first.is_a?(FFI::Pointer) || args.first.is_a?(GraphCutSeamFinderStruct) raise ArgumentError, "too many arguments for creating #{self.name} from Pointer" unless args.size == 1 return super(args.first) end # overloaded method wrapper for cv::detail::GraphCutSeamFinder::GraphCutSeamFinder(const std::string cost_type, float terminal_cost = 10000.f, float bad_region_penalty = 1000.f) @@cv_detail_graph_cut_seam_finder_graph_cut_seam_finder_defaults0 ||= [nil, 10000.0, 1000.0] if(args.size >= 1 && args.size <= 3) targs = args.clone targs.size.upto(2) do |i| targs[i] = @@cv_detail_graph_cut_seam_finder_graph_cut_seam_finder_defaults0[i] end begin return Rbind::cv_detail_graph_cut_seam_finder_graph_cut_seam_finder(*targs) rescue TypeError => e @error = e end end raise ArgumentError, "no constructor for #{self}(#{args.inspect})" end |
.null ⇒ Object
returns a null pointer to the object
16694 16695 16696 |
# File 'lib/ropencv/ropencv_types.rb', line 16694 def self.null new(GraphCutSeamFinderStruct.new) end |
Instance Method Details
#cast_to_graph_cut_seam_finder_base(parse_ownership) ⇒ Cv::Detail::GraphCutSeamFinderBase Also known as: castToGraphCutSeamFinderBase
Note:
method wrapper for cv::detail::GraphCutSeamFinderBase* cv::detail::GraphCutSeamFinder::castToGraphCutSeamFinderBase(bool parse_ownership)
16809 16810 16811 16812 16813 16814 16815 16816 16817 |
# File 'lib/ropencv/ropencv_types.rb', line 16809 def cast_to_graph_cut_seam_finder_base(parse_ownership) __validate_pointer__ result = Rbind::cv_detail_graph_cut_seam_finder_cast_to_graph_cut_seam_finder_base( self, parse_ownership) if result.respond_to?(:__owner__?) && !result.__owner__? # store owner insight the pointer to not get garbage collected result.instance_variable_get(:@__obj_ptr__).instance_variable_set(:@__owner__,self) end result end |
#cast_to_seam_finder(parse_ownership) ⇒ Cv::Detail::SeamFinder Also known as: castToSeamFinder
Note:
method wrapper for cv::detail::SeamFinder* cv::detail::GraphCutSeamFinder::castToSeamFinder(bool parse_ownership)
16823 16824 16825 16826 16827 16828 16829 16830 16831 |
# File 'lib/ropencv/ropencv_types.rb', line 16823 def cast_to_seam_finder(parse_ownership) __validate_pointer__ result = Rbind::cv_detail_graph_cut_seam_finder_cast_to_seam_finder( self, parse_ownership) if result.respond_to?(:__owner__?) && !result.__owner__? # store owner insight the pointer to not get garbage collected result.instance_variable_get(:@__obj_ptr__).instance_variable_set(:@__owner__,self) end result end |
#find(src, corners, masks) ⇒ Void
16801 16802 16803 16804 |
# File 'lib/ropencv/ropencv_types.rb', line 16801 def find(src, corners, masks) __validate_pointer__ Rbind::cv_detail_graph_cut_seam_finder_find( self, src, corners, masks) end |
#to_s ⇒ Object
converts GraphCutSeamFinder into a string by crawling through all its attributes
16787 16788 16789 |
# File 'lib/ropencv/ropencv_types.rb', line 16787 def to_s "#<cv::detail::GraphCutSeamFinder >" end |