I want to multiply every pixel in an image with a matrix, treating every pixel as a 3D-vector. In mathematical terms the operation would be something like:
u = M v
where u is the resulting pixel value, M the (3x3) matrix, and v the original pixel value.
I have searched the documentation but have not been able to find a way to do this in OpenCV. Does anybody have any suggestions?