Edge detection works in landscape but not in portrait mode - Android

asked 2019-06-28 02:00:26 -0500

ajay.k gravatar image

I have a sample of edge detection which is working fine in landscape mode. But when i change my activity orientation from landscape to portrait then preview is not with same orientation as of device. Then I found some code which rotate canvas in deliverAndDrawFrame() but in this case, processing of openCV is totally distorted. I also used Matrix to rotate mCacheBitmap but results is same only rotate preview.

I want to achieve same functionality in portrait mode as it is working in landscape mode.

edit retag flag offensive close merge delete