c++ - OpenCV: In a matrix, how to assign same value to all elements in a row -


for following expressions in matlab, what opencv equivalent?

a(2,:)=3; 

from know, can in opencv follows:

mat arepeated; repeat(value, 1, a.cols, arepeated); arepeated.copyto(a.row(1)); 

here value 1x1 mat value 3. there more efficient way wrote above?

this post suggested std::fill examples show usage vector object. i'm not sure if can applied mat objects well, or there other function. can guide please on this?

how about:

a.row(1).setto(scalar(value)); 

Comments

Popular posts from this blog

toolbar - How to add link to user registration inside toobar in admin joomla 3 custom component -

linux - disk space limitation when creating war file -

How to provide Authorization & Authentication using Asp.net, C#? -