Class: OpenCV::Cv::Ptr::Cv_CLAHE

Inherits:
Object
  • Object
show all
Extended by:
FFI::DataConverter
Defined in:
lib/ropencv/ropencv_types.rb

Specializing collapse

Class Method Summary collapse

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(m, *args) ⇒ Object



15880
15881
15882
15883
# File 'lib/ropencv/ropencv_types.rb', line 15880

def method_missing(m,*args)
    raise "Ptr cv::Ptr is empty. Cannot call #{m} on it!" if empty
    obj.method(m).call(*args)
end

Class Method Details

.new(*args) ⇒ Object

Parameters:

Raises:

  • (ArgumentError)


15741
15742
15743
15744
15745
15746
15747
15748
15749
15750
15751
15752
15753
15754
15755
15756
15757
15758
15759
15760
15761
# File 'lib/ropencv/ropencv_types.rb', line 15741

def self.new(*args)
    if args.first.is_a?(FFI::Pointer) || args.first.is_a?(Ptr::Cv_CLAHEStruct)
        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::Ptr<cv::CLAHE>::Ptr<cv::CLAHE>(cv::Ptr<cv::CLAHE> other)
    @@cv_ptr_cv_clahe_ptr_cv_clahe_defaults0 ||= [nil]
    if(args.size >= 1 && args.size <= 1)
        targs = args.clone
        targs.size.upto(0) do |i|
            targs[i] = @@cv_ptr_cv_clahe_ptr_cv_clahe_defaults0[i]
        end
        begin
                return Rbind::cv_ptr_cv_clahe_ptr_cv_clahe(*targs)
        rescue TypeError => e
            @error = e
        end
    end

    raise ArgumentError, "no constructor for #{self}(#{args.inspect})"
end

.nullObject

returns a null pointer to the object



15736
15737
15738
# File 'lib/ropencv/ropencv_types.rb', line 15736

def self.null
    new(Ptr::Cv_CLAHEStruct.new)
end

Instance Method Details

#addrefVoid

Note:

method wrapper for void cv::Ptrcv::CLAHE::addref()

methods

Returns:

  • (Void)


15838
15839
15840
15841
# File 'lib/ropencv/ropencv_types.rb', line 15838

def addref()
    __validate_pointer__
    Rbind::cv_ptr_cv_clahe_addref( self)
end

#delete_objVoid

Note:

method wrapper for void cv::Ptrcv::CLAHE::delete_obj()

Returns:

  • (Void)


15852
15853
15854
15855
# File 'lib/ropencv/ropencv_types.rb', line 15852

def delete_obj()
    __validate_pointer__
    Rbind::cv_ptr_cv_clahe_delete_obj( self)
end

#emptyBool

Note:

method wrapper for bool cv::Ptrcv::CLAHE::empty()

Returns:

  • (Bool)


15859
15860
15861
15862
# File 'lib/ropencv/ropencv_types.rb', line 15859

def empty()
    __validate_pointer__
    Rbind::cv_ptr_cv_clahe_empty( self)
end

#objCv::CLAHE Also known as: get_obj

Note:

method wrapper for cv::CLAHE* obj

Returns:



15866
15867
15868
15869
15870
15871
15872
15873
15874
# File 'lib/ropencv/ropencv_types.rb', line 15866

def obj()
    __validate_pointer__
    result = Rbind::cv_ptr_cv_clahe_get_obj( self)
    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

#releaseVoid

Note:

method wrapper for void cv::Ptrcv::CLAHE::release()

Returns:

  • (Void)


15845
15846
15847
15848
# File 'lib/ropencv/ropencv_types.rb', line 15845

def release()
    __validate_pointer__
    Rbind::cv_ptr_cv_clahe_release( self)
end

#to_sObject

converts Ptr::Cv_CLAHE into a string by crawling through all its attributes



15827
15828
15829
# File 'lib/ropencv/ropencv_types.rb', line 15827

def to_s
    "#<cv::Ptr<cv::CLAHE> obj=#{self.obj}>"
end