1 | initial version |
with this program
Mat z1(1,2,CV_32FC2),z2(1,2,CV_32FC2),z3;
z1.at<Vec2f>(0, 0) = Vec2f(1,1);//1+i
z1.at<Vec2f>(0, 1) = Vec2f(2,3);//2+3i
z2.at<Vec2f>(0, 0) = Vec2f(2,1);//2+i
z2.at<Vec2f>(0, 1) = Vec2f(3, 3);//3+3i
mulSpectrums(z1,z2,z3,0);
cout<<z3;//(1+i)*(2+i) and (2+i)*(3+3i)
waitKey();
result is
*
[1, 3, -3, 15] //(1+i)(2+i) and (2+i)(3+3i)
*