1 | initial version |
In your public Mat onCameraFrame(CvCameraViewFrame inputFrame) { }
Add following lines:
Mat rotImage = Imgproc.getRotationMatrix2D(new Point(mRgba.cols() / 2,
mRgba.rows() / 2), 90, 1.0);
Imgproc.warpAffine(mRgba, mRgba, rotImage, mRgba.size());
Imgproc.warpAffine(mGray, mGray, rotImage, mRgba.size());
Then set your activity to portrait in manifest