Class: OpenCV::Cv::Vec6i

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

Constant Summary collapse

SIZE =
6

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Vecxi

#[], #[]=, #to_a

Class Method Details

.vec_6iObject .vec_6i(other) ⇒ Object .vec_6i(_t0, _t1, _t2, _t3, _t4, _t5) ⇒ Object

Overloads:

  • .vec_6i(other) ⇒ Object

    Parameters:

  • .vec_6i(_t0, _t1, _t2, _t3, _t4, _t5) ⇒ Object

    Parameters:

    • _t0 (Fixnum)
    • _t1 (Fixnum)
    • _t2 (Fixnum)
    • _t3 (Fixnum)
    • _t4 (Fixnum)
    • _t5 (Fixnum)

Raises:

  • (ArgumentError)


9671
9672
9673
9674
9675
9676
9677
9678
9679
9680
9681
9682
9683
9684
9685
9686
9687
9688
9689
9690
9691
9692
9693
9694
9695
9696
9697
9698
9699
9700
9701
9702
9703
9704
9705
9706
9707
9708
9709
9710
9711
9712
9713
9714
9715
9716
9717
9718
9719
# File 'lib/ropencv/ropencv_types.rb', line 9671

def self.new(*args)
    if args.first.is_a?(FFI::Pointer) || args.first.is_a?(Vec6iStruct)
        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::Vec6i::Vec6i()
    @@cv_vec_6i_vec_6i_defaults0 ||= []
    if(args.size >= 0 && args.size <= 0)
        targs = args.clone
        targs.size.upto(-1) do |i|
            targs[i] = @@cv_vec_6i_vec_6i_defaults0[i]
        end
        begin
                return Rbind::cv_vec_6i_vec_6i(*targs)
        rescue TypeError => e
            @error = e
        end
    end

    # overloaded method wrapper for cv::Vec6i::Vec6i(cv::Vec6i other)
    @@cv_vec_6i_vec_6i__2_defaults1 ||= [nil]
    if(args.size >= 1 && args.size <= 1)
        targs = args.clone
        targs.size.upto(0) do |i|
            targs[i] = @@cv_vec_6i_vec_6i__2_defaults1[i]
        end
        begin
                return Rbind::cv_vec_6i_vec_6i__2(*targs)
        rescue TypeError => e
            @error = e
        end
    end

    # overloaded method wrapper for cv::Vec6i::Vec6i(int t0, int t1, int t2, int t3, int t4, int t5)
    @@cv_vec_6i_vec_6i__3_defaults2 ||= [nil, nil, nil, nil, nil, nil]
    if(args.size >= 6 && args.size <= 6)
        targs = args.clone
        targs.size.upto(5) do |i|
            targs[i] = @@cv_vec_6i_vec_6i__3_defaults2[i]
        end
        begin
                return Rbind::cv_vec_6i_vec_6i__3(*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



9655
9656
9657
# File 'lib/ropencv/ropencv_types.rb', line 9655

def self.null
    new(Vec6iStruct.new)
end

Instance Method Details

#!=(vec) ⇒ Bool

Note:

method wrapper for bool cv::Vec6i::operator!=(cv::Vec6i vec)

Parameters:

Returns:

  • (Bool)


9839
9840
9841
9842
# File 'lib/ropencv/ropencv_types.rb', line 9839

def !=(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_unequal( self, vec)
end

#*(vec) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::operator*(int vec)

Parameters:

  • vec (Fixnum)

Returns:



9863
9864
9865
9866
# File 'lib/ropencv/ropencv_types.rb', line 9863

def *(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_mult( self, vec)
end

#+(vec) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::operator+(cv::Vec6i vec)

Parameters:

Returns:



9847
9848
9849
9850
# File 'lib/ropencv/ropencv_types.rb', line 9847

def +(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_plus( self, vec)
end

#-(vec) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::operator-(cv::Vec6i vec)

Parameters:

Returns:



9855
9856
9857
9858
# File 'lib/ropencv/ropencv_types.rb', line 9855

def -(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_minus( self, vec)
end

#/(vec) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::operator/(int vec)

Parameters:

  • vec (Fixnum)

Returns:



9871
9872
9873
9874
# File 'lib/ropencv/ropencv_types.rb', line 9871

def /(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_div( self, vec)
end

#==(vec) ⇒ Bool

Note:

method wrapper for bool cv::Vec6i::operator==(cv::Vec6i vec)

Parameters:

Returns:

  • (Bool)


9831
9832
9833
9834
# File 'lib/ropencv/ropencv_types.rb', line 9831

def ==(vec)
    __validate_pointer__
    Rbind::cv_vec_6i_operator_equal( self, vec)
end

#all(alpha) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::all(int alpha)

Parameters:

  • alpha (Fixnum)

Returns:



9805
9806
9807
9808
9809
9810
9811
9812
9813
# File 'lib/ropencv/ropencv_types.rb', line 9805

def all(alpha)
    __validate_pointer__
    result = Rbind::cv_vec_6i_all( self, alpha)
    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

#mul(other) ⇒ Cv::Vec6i

Note:

method wrapper for cv::Vec6i cv::Vec6i::mul(cv::Vec6i other)

Parameters:

Returns:



9818
9819
9820
9821
9822
9823
9824
9825
9826
# File 'lib/ropencv/ropencv_types.rb', line 9818

def mul(other)
    __validate_pointer__
    result = Rbind::cv_vec_6i_mul( self, other)
    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

#to_sObject

converts Vec6i into a string by crawling through all its attributes



9785
9786
9787
# File 'lib/ropencv/ropencv_types.rb', line 9785

def to_s
    "#<cv::Vec6i val=#{self.val}>"
end

#valFixnum Also known as: get_val

Note:

method wrapper for int* val

methods

Returns:

  • (Fixnum)


9796
9797
9798
9799
# File 'lib/ropencv/ropencv_types.rb', line 9796

def val()
    __validate_pointer__
    Rbind::cv_vec_6i_get_val( self)
end