round, sin, cos, sqrt, atan2, mod, floor... functions in OpenCV!

asked 2015-04-02 09:44:52 -0500

dinhtuyen gravatar image

In matlab we have many function to perform an procedure for per element of matrix, example round, sin, cos, sqrt, atan2, mod, floor ......... here is an example:

A = [1.23 2.34 3; 5 6.78 7.89; 4.111 34.56 56.78]

A =

1.2300    2.3400    3.0000
5.0000    6.7800    7.8900
4.1110   34.5600   56.7800

B = round(A)

B =

 1     2     3
 5     7     8
 4    35    57

can you please give me some recommend to perform those function above.

example: cv::OutputArray round(cv::InputArray _src) { }

thank alot!

edit retag flag offensive close merge delete