1 | initial version |
Try this code it works for me:
public Mat onCameraFrame(CvCameraViewFrame inputFrame) {
mRgba = inputFrame.rgba();
Mat mRgbaT = mRgba.t();
Core.flip(mRgba.t(), mRgbaT, 1);
Imgproc.resize(mRgbaT, mRgbaT, mRgba.size());
return mRgbaT; }
Little explanation: first i load the input matrix, then i made a matrix pattern with the new size, then i flip it (so the image flip by 90 degrees) and finally i return to the original matrix size.