Module: CVFFI::CvMatFunctions::ClassMethods

Defined in:
lib/opencv-ffi-wrappers/core/mat.rb

Instance Method Summary collapse

Instance Method Details

#eye(x, type = :CV_32F) ⇒ Object



125
126
127
128
129
# File 'lib/opencv-ffi-wrappers/core/mat.rb', line 125

def eye( x, type = :CV_32F )
  a = CVFFI::cvCreateMat( x, x, type )
  CVFFI::cvSetIdentity( a, CVFFI::CvScalar.new( :w => 1, :x => 1, :y => 1, :z => 1 ) )
  a
end


131
132
133
# File 'lib/opencv-ffi-wrappers/core/mat.rb', line 131

def print( m, opts = {} )
  CVFFI::print_matrix( m, opts )
end