Confuse with camera Orientation
Solved
Mobile and Embedded
-
The orientation of Camera is weird
1 : on desktop, orientation 0, the image is top down like following
But on mobile(android), topDown orientation become 270
2 : When I save the image access by QAbstractVideoFilter, the image become upside down,but it is topDown on the screen(orientation is 0)
Image become topDown
How should I understand orientation value?Thanks
Codes :
ApplicationWindow { id: win visible: true //width: 640 //height: 480 title: qsTr("Hello World") Camera{ id: camera } SSDFilter { id: ssd_filter onMessageChanged: { console.log("msg is:" + msg) msg_text.text = "msg is:" + msg } orientation: video.orientation } Column{ VideoOutput { id: video source: camera width: win.width height: win.height - 20 autoOrientation: true filters: [ ssd_filter ] onOrientationChanged: { msg_text.text = "phone orientation:" + video.orientation } } Text{ id: msg_text } } }