First time here? Check out the FAQ!

Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

asked Jan 7 '14

Rauluka gravatar image

Adding row to Mat in Java

I have a problem with adding rows to Mat. I use push_back method but I get error: Sizes of input arguments do not match. Of course my Mats have same column length as it is said in method description.

Mat test = new Mat(new Size(10,100),5); Mat row = new Mat(new Size(1,100),5);

test.push_back(row);

^It will result in error which I described above. Do you have any ideas how insert a row to a matrix?

click to hide/show revision 2
No.2 Revision

updated Jan 8 '14

Haris gravatar image

Adding row to Mat in Java

I have a problem with adding rows to Mat. I use push_back method but I get error: Sizes of input arguments do not match. Of course my Mats have same column length as it is said in method description.

Mat test = new Mat(new Size(10,100),5);
Mat row = new Mat(new Size(1,100),5);

test.push_back(row);

Size(1,100),5); test.push_back(row);

^It will result in error which I described above. Do you have any ideas how insert a row to a matrix?

click to hide/show revision 3
retagged

updated Jan 8 '14

berak gravatar image

Adding row to Mat in Java

I have a problem with adding rows to Mat. I use push_back method but I get error: Sizes of input arguments do not match. Of course my Mats have same column length as it is said in method description.

Mat test = new Mat(new Size(10,100),5);
Mat row = new Mat(new Size(1,100),5);
test.push_back(row);

^It will result in error which I described above. Do you have any ideas how insert a row to a matrix?