Undefined cv::Mat Behavior

Thanks to everyone for their input! I’ve finally found out why there was unexpected behavior with the cv::Mat objects in my program!

After further testing, I found out that the issue only arose when running the program in release mode. In debug mode, the values were not only read properly from file, but also passed correctly to the cv::Mat object.

The issue was that the localization settings for my installed OS were using the DE-standard for numbers, which interprets all periods (.) in numbers as a thousandths separator, NOT a decimal! Thus, the program decided to truncate the fraction part of the double variables.

Going into the localization settings of my PC (locale for me, since I’m currently using Ubuntu,) I changed how the system interpreted numerics, and the problem was solved!

Thanks again for everyone’s input and patience with me!
C.Fox