Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The error is not in the .at<double>() function. It is properly returning a double. You are trying to assign that double to a Mat, which doesn't work.

Either change Thz to a double, or create it as a 1x1 matrix and use<double>(0,0) = atan2(...