Class: OpenCV::Cv::Ptr::Cv_Flann_IndexParams

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



27058
27059
27060
27061
# File 'lib/ropencv/ropencv_types.rb', line 27058

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)


26919
26920
26921
26922
26923
26924
26925
26926
26927
26928
26929
26930
26931
26932
26933
26934
26935
26936
26937
26938
26939
# File 'lib/ropencv/ropencv_types.rb', line 26919

def self.new(*args)
    if args.first.is_a?(FFI::Pointer) || args.first.is_a?(Ptr::Cv_Flann_IndexParamsStruct)
        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::flann::IndexParams>::Ptr<cv::flann::IndexParams>(cv::Ptr<cv::flann::IndexParams> other)
    @@cv_ptr_cv_flann_index_params_ptr_cv_flann_index_params_defaults0 ||= [nil]
    if(args.size >= 1 && args.size <= 1)
        targs = args.clone
        targs.size.upto(0) do |i|
            targs[i] = @@cv_ptr_cv_flann_index_params_ptr_cv_flann_index_params_defaults0[i]
        end
        begin
                return Rbind::cv_ptr_cv_flann_index_params_ptr_cv_flann_index_params(*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



26914
26915
26916
# File 'lib/ropencv/ropencv_types.rb', line 26914

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

Instance Method Details

#addrefVoid

Note:

method wrapper for void cv::Ptrcv::flann::IndexParams::addref()

methods

Returns:

  • (Void)


27016
27017
27018
27019
# File 'lib/ropencv/ropencv_types.rb', line 27016

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

#delete_objVoid

Note:

method wrapper for void cv::Ptrcv::flann::IndexParams::delete_obj()

Returns:

  • (Void)


27030
27031
27032
27033
# File 'lib/ropencv/ropencv_types.rb', line 27030

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

#emptyBool

Note:

method wrapper for bool cv::Ptrcv::flann::IndexParams::empty()

Returns:

  • (Bool)


27037
27038
27039
27040
# File 'lib/ropencv/ropencv_types.rb', line 27037

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

#objCv::Flann::IndexParams Also known as: get_obj

Note:

method wrapper for cv::flann::IndexParams* obj



27044
27045
27046
27047
27048
27049
27050
27051
27052
# File 'lib/ropencv/ropencv_types.rb', line 27044

def obj()
    __validate_pointer__
    result = Rbind::cv_ptr_cv_flann_index_params_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::flann::IndexParams::release()

Returns:

  • (Void)


27023
27024
27025
27026
# File 'lib/ropencv/ropencv_types.rb', line 27023

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

#to_sObject

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



27005
27006
27007
# File 'lib/ropencv/ropencv_types.rb', line 27005

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