como llenar un Mat [closed]

asked 2015-01-25 20:40:43 -0600

Estoy utilizando opencv y lo que quiero hacer es poner un numero en una posición determinada de un Mat, por ejemplo, en un objeto Mat de 1 fila y 4 columnas, quisiera poner el numero 3 en la posición 1,2,

Mat m=new Mat(1,4,opencv_core.CV_32SC1);

pero no se como hacer, intente con m.put(1,2,3) pero no funciona, lo único que acepta como argumento es un Mat, MatExpr, Pointer o un Scalar

edit retag flag offensive reopen merge delete

Closed for the following reason too localized by FooBar
close date 2015-01-26 05:59:19.242527

Comments

In case you haven't noticed, this is an english speaking forum...

FooBar gravatar imageFooBar ( 2015-01-26 05:59:53 -0600 )edit

I ll contribute with a translation if it helps..

I am using opencv and what I want to do is to put a number in a specified position in a Mat. For instance, in a Mat with 1 row and 4 columns, I would like to put number 3 on position 1,2. Mat m= new Mat(1,4,opencv_core.CV_32SC!) but I dont know how to do this. I tried with m.put(1,2,3) but it doesnt work. The arguments have to be Mat, MatExpr, Pinter or Scalar.

KansaiRobot gravatar imageKansaiRobot ( 2015-01-26 18:33:12 -0600 )edit