简体   繁体   中英

In Android CameraBridgeViewBase class, How to set opencv camera for Portrait orientation in Full screen mode

I was using opencv cameraBridgeViewBase Class, in Normal portrait mode camera angle is rotated. so i use to traspose and flip, camera angle rotated to normal portrait mode.

Core.transpose(mRgba, mRgbaT);
Imgproc.resize(mRgbaT, mRgbaF, mRgbaF.size(), 0,0, 0);
Core.flip(mRgbaF, mRgba, 0);

But camera view is center of the screen , not able to get full screen mode. Is anything possible to change full screen mode or without transpose and flip to change full screen mode for portrait please justify me thank you..

I'm not sure if I understood your problem. But if you want to keep your OpenCV application full screen no matter if you tilt/rotate your phone, one easy thing to do in order to overcome this problem would be: Go to your Android manifest and add android:screenOrientation="landscape" before the line: android:label="@string/app_name"

Keep us updated if it worked for you

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM