{"id":318767,"date":"2021-02-28T15:00:36","date_gmt":"2021-02-28T15:00:36","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=318767"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=318767","title":{"rendered":"\u0424\u043e\u0442\u043e \u0438\u0437 Android \u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0432 Qt Widgets"},"content":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0447\u0438\u0442\u0430\u0442\u044c \u0438\u043b\u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u0430, \u043e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0432 \u043a\u043e\u043d\u0446\u0435 \u0441\u0442\u0430\u0442\u044c\u0438.<\/p>\n<h2>\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b<\/h2>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u0438\u0448\u0435\u0442\u0435 \u043a\u0440\u043e\u0441\u0441-\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0442\u043e \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b \u0434\u043b\u044f \u041f\u041a \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u043b\u0430\u0441\u0441\u043e\u043c <a href=\"https:\/\/doc.qt.io\/qt-5\/qcamera.html\" rel=\"noopener noreferrer nofollow\"><strong>QCamera<\/strong><\/a>, <a href=\"https:\/\/doc.qt.io\/qt-5\/qtmultimedia-multimediawidgets-camera-example.html\" rel=\"noopener noreferrer nofollow\">\u043f\u0440\u0438\u043c\u0435\u0440<\/a> \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043e\u043f\u0438\u0441\u0430\u043d \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Qt.<\/p>\n<p>\u0412 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u043c \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0432 .pro \u0444\u0430\u0439\u043b <\/p>\n<p><code>QT += multimedia multimediawidgets<\/code> <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u0432\u0438\u0434\u0436\u0435\u0442 \u0432 \u0441\u0432\u043e\u0435\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u044e\u0449\u0438\u0439 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0438\u0437 \u0432\u0435\u0431-\u043a\u0430\u043c\u0435\u0440\u044b \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u044e\u0449\u0438\u0439 \u0435\u0433\u043e \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qpixmap.html\" rel=\"noopener noreferrer nofollow\">QPixmap<\/a> \u0438\u043b\u0438 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u0437\u0430\u0434\u0430\u0447\u0430 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u043e-\u0436\u0435 \u0441\u0430\u043c\u043e\u0435 \u043d\u0430 Android, \u0442\u043e \u0432\u044b\u044f\u0441\u043d\u044f\u0435\u0442\u0441\u044f, \u0447\u0442\u043e <strong>multimediawidgets <\/strong>\u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0434\u0430\u043d\u043d\u043e\u0439 \u041e\u0421 \u0438 \u043a\u0430\u043c\u0435\u0440\u0430 \u0441\u043d\u0438\u043c\u0430\u0442\u044c \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0442\u044c \u0441\u043d\u0438\u043c\u043a\u0438 \u0431\u0443\u0434\u0435\u0442, \u043d\u043e \u0447\u0442\u043e \u043e\u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u0433\u0430\u0434\u043a\u043e\u0439, \u0442.&nbsp;\u043a. <a href=\"https:\/\/doc.qt.io\/qt-5\/qcameraviewfinder.html\" rel=\"noopener noreferrer nofollow\"><strong>QCameraViewfinder<\/strong><\/a> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 <strong>multimediawidgets <\/strong>\u0438 \u043d\u0430 Android \u043d\u0435 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u043d\u0438\u0447\u0435\u0433\u043e. \u0414\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0438\u0439 \u043f\u043e\u0438\u0441\u043a \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0434\u0432\u0443\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u044f:<\/p>\n<ol>\n<li>\n<p>\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0439 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtquickcontrols-index.html\" rel=\"noopener noreferrer nofollow\">Qt Quick-\u044d\u043b\u0435\u043c\u0435\u043d\u0442<\/a>, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0439 \u044d\u0442\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u0437\u0430\u0442\u0435\u043c \u0441\u043e\u0441\u0442\u044b\u043a\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043d\u0430 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtwidgets-index.html\" rel=\"noopener noreferrer nofollow\">Qt Widgets<\/a>, \u0421++;<\/p>\n<\/li>\n<li>\n<p>\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438, \u0437\u0430\u0442\u0435\u043c \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0435\u0451 \u0432 \u0441\u0432\u043e\u0451\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438.<\/p>\n<\/li>\n<\/ol>\n<h3>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0435\u0440\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442<\/h3>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0421++ \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0441\u0442 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtwidgets-index.html\" rel=\"noopener noreferrer nofollow\">Qt Widgets<\/a>, \u0442\u043e \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0435 \u044d\u043f\u0438\u0437\u043e\u0434\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u0433\u043b\u0443\u0431\u043b\u0435\u043d\u0438\u0435 \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u0437\u0430\u0439\u043c\u0451\u0442 \u0443 \u0432\u0430\u0441 \u0432\u0440\u0435\u043c\u044f, \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043a \u044d\u0442\u043e\u043c\u0443 \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtquickcontrols-index.html\" rel=\"noopener noreferrer nofollow\">Qt Quick-\u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430<\/a>, \u0441\u0442\u044b\u043a\u043e\u0432\u043a\u0438 \u044d\u0442\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0441 \u0421++ \u043a\u043e\u0434\u043e\u043c, \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430. \u0415\u0441\u043b\u0438 \u0432\u044b \u043d\u0435 \u043f\u0440\u043e\u0444\u0435\u0441\u0441\u0438\u043e\u043d\u0430\u043b \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u0434\u043e\u043b\u0433\u043e \u0438 \u0441\u043b\u043e\u0436\u043d\u043e.<\/p>\n<h3>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442<\/h3>\n<p>\u0412 Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0435 \u0443\u0436\u0435 \u0435\u0441\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0435\u0435 \u043d\u0443\u0436\u043d\u0443\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u043d\u0443\u0436\u043d\u043e \u0438\u043c \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f, \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0432 Java-\u0432\u044b\u0437\u043e\u0432\u044b (<a href=\"https:\/\/ru.wikipedia.org\/wiki\/Java_Native_Interface\" rel=\"noopener noreferrer nofollow\">JNI \u2014 Java Native Interface<\/a>) \u0438\u0437 \u0421++ \u043a\u043e\u0434\u0430 \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtandroid.html\" rel=\"noopener noreferrer nofollow\"><strong>QtAndroid<\/strong><\/a>. \u0412\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u043e\u0449\u0435. \u041f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0435\u0433\u043e \u043a\u043e\u0434\u0430 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u044f \u043d\u0435 \u043d\u0430\u0448\u0451\u043b, \u0438, \u0438\u0437\u0443\u0447\u0438\u0432 \u043e\u043f\u044b\u0442 \u0434\u0440\u0443\u0433\u0438\u0445, \u043e\u043f\u0438\u0440\u0430\u044f\u0441\u044c \u043d\u0430 <a href=\"https:\/\/developer.android.com\/reference\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u043a\u0430 \u043d\u0430 Android<\/a> \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439.<\/p>\n<h2>\u041a\u0430\u043a \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c<\/h2>\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0447\u0438\u0442\u0430\u0442\u044c \u0438\u043b\u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u0430, \u043e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0432 \u043a\u043e\u043d\u0446\u0435 \u0441\u0442\u0430\u0442\u044c\u0438.<\/p>\n<p>\u041f\u0440\u043e\u0447\u0438\u0442\u0430\u0432 \u0441\u0442\u0430\u0442\u044c\u044e <a href=\"https:\/\/developer.android.com\/training\/camera\/photobasics\" rel=\"noopener noreferrer nofollow\">\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438 \u043d\u0430 Android<\/a> \u044f \u0441\u0434\u0435\u043b\u0430\u043b \u0432\u044b\u0432\u043e\u0434, \u0447\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0432 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u043b\u0438 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432 \u0432\u0438\u0434\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439 \u0438\u043b\u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0432 \u0444\u0430\u0439\u043b. \u041f\u043e\u0438\u0441\u043a\u0430\u0432 \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f, \u044f \u043d\u0430\u0448\u0451\u043b \u043d\u0430 <a href=\"https:\/\/github.com\/minixxie\/examples\/blob\/master\/qt-for-mobile\/TestExternalAndroidCamera1\/MyController.cpp\" rel=\"noopener noreferrer nofollow\">GitHub \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0438\u0439 \u043a\u043e\u0434<\/a>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u043b \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u043c\u043d\u0435 \u0437\u0430\u0434\u0430\u0447\u0443. \u041f\u0440\u0438 \u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0435, \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043e\u043d \u0443\u0441\u0442\u0430\u0440\u0435\u043b \u0438 \u0442\u0435\u043f\u0435\u0440\u044c \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a <a href=\"https:\/\/developer.android.com\/reference\/android\/os\/FileUriExposedException\" rel=\"noopener noreferrer nofollow\">FileUriExposedException<\/a> \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044e, \u043f\u0440\u0438\u0447\u0438\u043d\u044b \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u043e\u0432\u0435\u043d\u0438\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u044b \u0432 \u0432\u044b\u0448\u0435\u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0435 \u043d\u0430 \u0441\u0442\u0430\u0442\u044c\u044e.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4f6\/934\/ac8\/4f6934ac8f911059268ab42821b45b1d.gif\" width=\"855\" height=\"103\"><figcaption><\/figcaption><\/figure>\n<p>\u0427\u0442\u043e\u0431\u044b \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e, \u043a\u0430\u043a \u043e\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043d\u0430\u0447\u043d\u0451\u043c \u0441 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0437\u0430\u0434\u0430\u0447\u0438, \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0449\u0435\u0439 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u043a \u0444\u0430\u0439\u043b\u0430\u043c \u0438 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0430 Java-\u0432\u044b\u0437\u043e\u0432\u043e\u0432 \u2014 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b.<\/p>\n<h3>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b<\/h3>\n<p>\u041d\u0430\u0447\u043d\u0451\u043c \u0441 .pro \u0444\u0430\u0439\u043b\u0430.  <\/p>\n<p>\u041e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 Android.<\/p>\n<pre><code>android {     QT       +=androidextras }<\/code><\/pre>\n<p>\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u043a\u043b\u0430\u0441\u0441, \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043e\u0442 <a href=\"https:\/\/doc.qt.io\/qt-5\/qandroidactivityresultreceiver.html\" rel=\"noopener noreferrer nofollow\">QAndroidActivityResultReceiver<\/a>. \u0415\u0441\u043b\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u044a\u0435\u043a\u0442 \u043d\u0430\u0448\u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432\u044b\u0441\u044b\u043b\u0430\u043b \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u0441\u0438\u0433\u043d\u0430\u043b\u0430, \u0442\u043e \u043e\u043d \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d \u043e\u0442 \u043b\u044e\u0431\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 Qt, \u0438\u043c\u0435\u044e\u0449\u0435\u0433\u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 <a href=\"https:\/\/doc.qt.io\/qt-5\/qobject.html\" rel=\"noopener noreferrer nofollow\">QObject<\/a>. <\/p>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.h) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">#ifndef CAMSHOT_H #define CAMSHOT_H #include &lt;QObject&gt; #include &lt;QString&gt; #include &lt;cstring&gt; #include &lt;QImage&gt; #include &lt;QDebug&gt; #include &lt;QtAndroid&gt; #include &lt;QAndroidActivityResultReceiver&gt; #include &lt;QAndroidParcel&gt; class CamShot : public QObject, public QAndroidActivityResultReceiver {     Q_OBJECT public:     CamShot(QObject *parent = nullptr):QObject(parent),QAndroidActivityResultReceiver(){}          static const int RESULT_OK = -1;      static const int REQUEST_IMAGE_CAPTURE = 1;     static const int REQUEST_TAKE_PHOTO = REQUEST_IMAGE_CAPTURE;     void handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data)  override;     static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data); public slots:     void aMakeShot(); signals:     void createNew(const QImage &amp;img); };  #endif \/\/ CAMSHOT_H<\/code><\/pre>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.cpp) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">QImage CamShot::camThumbnailToQImage(const QAndroidJniObject &amp;data){     QAndroidJniObject bundle = data.callObjectMethod(\"getExtras\",\"()Landroid\/os\/Bundle;\");     qDebug()&lt;&lt;\"bundle.isValid() \"&lt;&lt;bundle.isValid()&lt;&lt;bundle.toString();     QAndroidJniObject bundleKey = QAndroidJniObject::fromString(\"data\");     const QAndroidJniObject aBitmap (data.callObjectMethod(\"getParcelableExtra\", \"(Ljava\/lang\/String;)Landroid\/os\/Parcelable;\", bundleKey.object&lt;jstring&gt;()));     qDebug()&lt;&lt;\"aBitmap.isValid() \"&lt;&lt;aBitmap.isValid()&lt;&lt;aBitmap.toString();     jint aBitmapWidth = aBitmap.callMethod&lt;jint&gt;(\"getWidth\");     jint aBitmapHeight = aBitmap.callMethod&lt;jint&gt;(\"getHeight\");     QAndroidJniEnvironment env;     const int32_t aBitmapPixelsCount = aBitmapWidth * aBitmapHeight;     jintArray pixels = env-&gt;NewIntArray(aBitmapPixelsCount);     jint aBitmapOffset = 0;     jint aBitmapStride = aBitmapWidth;     jint aBitmapX = 0;     jint aBitmapY = 0;     aBitmap.callMethod&lt;void&gt;(\"getPixels\",\"([IIIIIII)V\", pixels, aBitmapOffset, aBitmapStride, aBitmapX, aBitmapY, aBitmapWidth, aBitmapHeight);     jint *pPixels = env-&gt;GetIntArrayElements(pixels, nullptr);     QImage img(aBitmapWidth, aBitmapHeight, QImage::Format_ARGB32);     int lineSzB = aBitmapWidth * sizeof(jint);     for (int i = 0; i &lt; aBitmapHeight; ++i){         uchar *pDst = img.scanLine(i);         const uchar *pSrc = reinterpret_cast&lt;const uchar*&gt;(pPixels + aBitmapWidth * i + aBitmapWidth);         memcpy(pDst, pSrc, lineSzB);     }     env-&gt;DeleteLocalRef(pixels); \/\/env-&gt;ReleaseIntArrayElements(pixels, pPixels, 0); \u043e\u0442\u0432\u044f\u0437\u044b\u0432\u0430\u0435\u0442 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c \u043d\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u043e\u0442 \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u0430 \u043d\u0430\u0434\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0441\u0430\u043c \u043c\u0430\u0441\u0441\u0438\u0432, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 DeleteLocalRef.      return img; } void CamShot::aMakeShot() {     QAndroidJniObject action = QandroidJniObject::fromString(\"android.media.action.IMAGE_CAPTURE\");     \/\/\u0415\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c Java-\u043a\u043b\u0430\u0441\u0441 (\u043d\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438), \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u043d\u043e\u0435 \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442\u043e\u0447\u043a\u0438-\u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430 \"\/\"), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440  \"android\/content\/Intent\", \"java\/lang\/String\".     \/\/\u0415\u0441\u043b\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 Java-\u043e\u0431\u044a\u0435\u043a\u0442, \u0442\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 \"L\" \u0438 \";\" \u0432 \u043a\u043e\u043d\u0446\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \"Landroid\/content\/Intent ;\", \"Ljava\/lang\/String;\".     \/\/\u0415\u0441\u043b\u0438 \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0439 \u0442\u0438\u043f \u0438\u043b\u0438 \u043c\u0430\u0441\u0441\u0438\u0432, \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0431\u0435\u0437 \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0435\u0439, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \"V\" (void) \u0438\u043b\u0438 \"[IIIIIII\" (\u043c\u0430\u0441\u0441\u0438\u0432 jint, \u0438 6 jint \u0437\u0430 \u043d\u0438\u043c)     \/\/\u0421\u0438\u043c\u0432\u043e\u043b\u044b, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u044f \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b \u0442\u0438\u043f\u0430\u043c:     QAndroidJniObject intent=QAndroidJniObject(\"android\/content\/Intent\",\"(Ljava\/lang\/String;)V\", action.object&lt;jstring&gt;());     QtAndroid::startActivity(intent, REQUEST_IMAGE_CAPTURE, this); } void CamShot::handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data){     if ( receiverRequestCode == REQUEST_IMAGE_CAPTURE &amp;&amp; resultCode == RESULT_OK )     {         const QImage thumbnail (camThumbnailToQImage(data));         if (!thumbnail.isNull())             emit createNew(thumbnail);     } }<\/code><\/pre>\n<h4>\u0420\u0430\u0437\u0431\u0435\u0440\u0451\u043c \u043f\u0440\u0438\u0432\u0435\u0434\u0451\u043d\u043d\u044b\u0439 \u043a\u043e\u0434<\/h4>\n<h4>\u041a\u0440\u0430\u0442\u043a\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0443\u043a\u0430\u0437\u0430\u043d\u0438\u044f \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 JNI-\u0432\u044b\u0437\u043e\u0432\u0430\u0445<\/h4>\n<ol>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0438\u043c\u044f Java-\u043a\u043b\u0430\u0441\u0441\u0430 (\u043d\u0435 \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 Java-\u0444\u0443\u043d\u043a\u0446\u0438\u0438), \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u043d\u043e\u0435 \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442\u043e\u0447\u043a\u0438-\u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430 &#171;<strong>\/<\/strong>&#171;), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>android\/content\/Intent<\/strong>&#171;, &#171;<strong>java\/lang\/String<\/strong>&#171;;<\/p>\n<\/li>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 Java-\u043e\u0431\u044a\u0435\u043a\u0442, \u0442\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438\u043c\u044f \u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 &#171;<strong>L<\/strong>&#187; \u0438 &#171;<strong>;<\/strong>&#187; \u0432 \u043a\u043e\u043d\u0446\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>Landroid\/content\/Intent;<\/strong>&#171;, &#171;<strong>Ljava\/lang\/String;<\/strong>&#171;;<\/p>\n<\/li>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0439 \u0442\u0438\u043f \u0438\u043b\u0438 \u043c\u0430\u0441\u0441\u0438\u0432, \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b (\u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0431\u0435\u0437 \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0435\u0439), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>V<\/strong>&#187; (void), &#171;<strong>I<\/strong>&#187; (jint) \u0438\u043b\u0438 &#171;<strong>[IIIIIII<\/strong>&#187; (\u043c\u0430\u0441\u0441\u0438\u0432 jint, \u0438 6 jint \u0437\u0430 \u043d\u0438\u043c);<\/p>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0445 \u0442\u0438\u043f\u043e\u0432:<code>    <\/code><\/p>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"244\" width=\"244\">\n<p align=\"center\">C\/C++<\/p>\n<\/th>\n<th>\n<p align=\"center\">JNI<\/p>\n<\/th>\n<th data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">Java<\/p>\n<\/th>\n<th data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Signature<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>uint8_t\/unsigned char<\/p>\n<\/td>\n<td>\n<p align=\"center\">jboolean<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">bool<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Z<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int8_t\/char\/signed char<\/p>\n<\/td>\n<td>\n<p align=\"center\">jbyte<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">byte<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">B<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>uint16_t\/unsigned short<\/p>\n<\/td>\n<td>\n<p align=\"center\">jchar<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">char<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">C<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int16_t\/short<\/p>\n<\/td>\n<td>\n<p align=\"center\">jshort<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">short<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">S<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int32_t\/int\/(long)<\/p>\n<\/td>\n<td>\n<p align=\"center\">jint<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">int<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">I<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int64_t\/(long)\/long long<\/p>\n<\/td>\n<td>\n<p align=\"center\">jlong<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">long<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">J<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>float<\/p>\n<\/td>\n<td>\n<p align=\"center\">jfloat<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">float<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">F<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>double<\/p>\n<\/td>\n<td>\n<p align=\"center\">jdouble<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">double<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">D<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>void<\/p>\n<\/td>\n<td>\n<p>                  <\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">void<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">V<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b \u043c\u0430\u0441\u0441\u0438\u0432\u043e\u0432:<code>    <\/code><\/p>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"216\" width=\"216\">\n<p align=\"center\">JNI<\/p>\n<\/th>\n<th data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Java<\/p>\n<\/th>\n<th>\n<p align=\"center\">Signature<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jbooleanArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">bool[]<\/p>\n<\/td>\n<td>\n<p>[Z<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jbyteArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">byte[]<\/p>\n<\/td>\n<td>\n<p>[B<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jcharArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">char[]<\/p>\n<\/td>\n<td>\n<p>[C<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jshortArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">short[]<\/p>\n<\/td>\n<td>\n<p>[S<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jintArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">int[]<\/p>\n<\/td>\n<td>\n<p>[I<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jlongArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">long[]<\/p>\n<\/td>\n<td>\n<p>[L<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jfloatArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">float[]<\/p>\n<\/td>\n<td>\n<p>[F<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jdoubleArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">double[]<\/p>\n<\/td>\n<td>\n<p>[D<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jarray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">type[]<\/p>\n<\/td>\n<td>\n<p>[Lfully\/qualified\/type\/name;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jarray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">String[]<\/p>\n<\/td>\n<td>\n<p>[Ljava\/lang\/String;<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>\u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c JNI-\u043c\u0435\u0442\u043e\u0434\u044b \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/doc.qt.io\/qt-5\/qandroidjnienvironment.html\" rel=\"noopener noreferrer nofollow\">QAndroidJniEnvironment<\/a>, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a: NewIntArray, GetIntArrayElements, DeleteLocalRef GetArrayLength,GetObjectArrayElement, SetObjectArrayElement, \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ol>\n<p>\u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0432 \u043f\u0440\u0435\u0437\u0435\u043d\u0442\u0430\u0446\u0438\u0438 (pdf) <a href=\"https:\/\/www.google.com\/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=&amp;cad=rja&amp;uact=8&amp;ved=2ahUKEwjTqrvL0_3uAhXukosKHfHTAQIQFjABegQIAhAD&amp;url=https%3A%2F%2Fconf.qtcon.org%2Fsystem%2Fattachments%2F132%2Foriginal%2FQtCon16.pdf%253F1473147092&amp;usg=AOvVaw29H2FMnsBW5AMFGk0lNwot\" rel=\"noopener noreferrer nofollow\">Practical Qt on Android JNI \u2014 qtcon<\/a>.<\/p>\n<p>\u0412 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 class <strong>CamShot <\/strong>\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442:<\/p>\n<ol>\n<li>\n<p>\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f     \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442, \u0432\u0437\u044f\u0442\u044b\u0445 \u0438\u0445 <a href=\"https:\/\/developer.android.com\/training\/camera\/photobasics\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438     \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u043a\u0430 Android<\/a> (\u0442\u0430\u043a     \u043a\u043e\u0434 \u043a\u043e\u0440\u043e\u0447\u0435 \u0438 \u043c\u0435\u043d\u044c\u0448\u0435 Java-\u0432\u044b\u0437\u043e\u0432\u043e\u0432);<\/p>\n<\/li>\n<li>\n<p>\u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u043e\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430 <code>void handleActivityResult(int  receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data) override;<\/code> \u0432  \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f Java-\u043e\u0431\u044a\u0435\u043a\u0442     \u043a\u043b\u0430\u0441\u0441\u0430     <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>     \u0441     \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u043e\u0439 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f;<\/p>\n<\/li>\n<li>\n<p>\u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u0435\u0442\u043e\u0434<br \/><code>static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data);<\/code><br \/>\u0438\u0437\u0432\u043b\u0435\u043a\u0430\u044e\u0449\u0438\u0439 \u0438\u0437 Java-\u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>     Java-\u043e\u0431\u044a\u0435\u043a\u0442 \u043a\u043b\u0430\u0441\u0441\u0430     <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a>,     \u043a\u043e\u043f\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0438 \u0432 \u043c\u0430\u0441\u0441\u0438\u0432 \u043f\u043a\u0441\u0435\u043b\u0435\u0439     (32-\u0431\u0438\u0442\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439) \u0438 \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u044e\u0449\u0438\u0439     \u044d\u0442\u0438 \u043f\u0438\u043a\u0441\u0435\u043b\u0438 \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a>;<\/p>\n<\/li>\n<li>\n<p>\u043e\u0431\u0449\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0439 \u0441\u043b\u043e\u0442<br \/><code>void aMakeShot();<\/code><br \/>\u0432\u044b\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044e \u043f\u043e \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e     \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044e \u0435\u0433\u043e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b;<\/p>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u043b<br \/><code>void createNew(const QImage &amp;img);<\/code><br \/>\u0432\u044b\u0441\u044b\u043b\u0430\u044e\u0449\u0438\u0439 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u0443\u044e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u044e.<\/p>\n<\/li>\n<\/ol>\n<p>\u0412 \u043c\u0435\u0442\u043e\u0434\u0435 void <strong>aMakeShot<\/strong>() \u0441\u043e\u0437\u0434\u0430\u0451\u0442\u0441\u044f Java-\u043e\u0431\u044a\u0435\u043a\u0442 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a> \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u0441\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c, \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u043c, \u0447\u0442\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u2014 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0441\u0442\u0438 \u0437\u0430\u0445\u0432\u0430\u0442 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f. \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0441\u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 (<a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>) \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 (<a href=\"https:\/\/developer.android.com\/reference\/android\/app\/Activity\" rel=\"noopener noreferrer nofollow\">Activity<\/a>).<\/p>\n<p>\u0412 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0434\u043b\u044f \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u041a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u043d\u0430 \u0438 \u043f\u043e\u0434\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c, \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0451\u043d \u0432\u044b\u0437\u043e\u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430 <strong><em>handleActivityResult<\/em><\/strong>, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430: \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0437\u0430\u043f\u0440\u043e\u0448\u0435\u043d\u043d\u044b\u043c \u0438 \u0443\u0441\u043f\u0435\u0448\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u044b\u043c. \u0415\u0441\u043b\u0438 \u0434\u0430, \u0442\u043e \u0432\u044b\u0437\u043e\u0432\u0435\u043c \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u0435\u0442\u043e\u0434 <strong>camThumbnailToQImage<\/strong> \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0438\u0437 Java-\u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a> \u0438 \u043f\u0440\u0438 \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043c \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u044e \u0441\u0438\u0433\u043d\u0430\u043b\u043e\u043c Qt.<\/p>\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u0435\u0442\u043e\u0434<br \/><code>static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data) override;<\/code><\/p>\n<p>\u0418\u043d\u0442\u0435\u0440\u0435\u0441\u0443\u044e\u0449\u0435\u0435 \u043d\u0430\u0441 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f \u0432 \u0431\u043b\u043e\u043a\u0435 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 Java-\u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a> \u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f Java-\u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/os\/Bundle\" rel=\"noopener noreferrer nofollow\">Bundle<\/a>, \u0447\u0442\u043e\u0431\u044b \u0435\u0433\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043d\u0443\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>:<br \/><a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent#getExtras()\" rel=\"noopener noreferrer nofollow\">Bundle getExtras()<\/a><\/p>\n<p>\u0412 <a href=\"https:\/\/developer.android.com\/reference\/android\/os\/Bundle\" rel=\"noopener noreferrer nofollow\">Bundle<\/a> \u0445\u0440\u0430\u043d\u044f\u0442\u0441\u044f \u0430\u0441\u0441\u043e\u0446\u0438\u0430\u0442\u0438\u0432\u043d\u044b\u0435 \u043f\u0430\u0440\u044b &lt;\u043a\u043b\u044e\u0447-\u0441\u0442\u0440\u043e\u043a\u0430&gt;:&lt;\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435&gt;. \u0412 \u0441\u0442\u0430\u0442\u044c\u0435 <a href=\"https:\/\/developer.android.com\/training\/camera\/photobasics\" rel=\"noopener noreferrer nofollow\">\u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438 \u043d\u0430 Android<\/a> \u0443\u043a\u0430\u0437\u0430\u043d \u043a\u043b\u044e\u0447, \u043f\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u0440\u0430\u0441\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0430. \u042d\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0430 &#171;data&#187;.<\/p>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043c Java-\u043e\u0431\u044a\u0435\u043a\u0442 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a> \u043f\u043e \u043a\u043b\u044e\u0447\u0443, \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0432\u0448\u0438\u0441\u044c \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>:<br \/><a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent#getParcelableExtra(java.lang.String)\" rel=\"noopener noreferrer nofollow\">T getParcelableExtra (String name)<\/a><\/p>\n<p>C\u043e\u0431\u0440\u0430\u0442\u044c \u0438\u0437 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a> <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0441\u0440\u0430\u0437\u0443 \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f, \u0442.&nbsp;\u043a. \u0443 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a> \u043d\u0435\u0442 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044f \u043d\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u043e\u043c \u0435\u0433\u043e \u0444\u043e\u0440\u043c\u0430\u0442\u0430. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0435\u0433\u043e \u0440\u0430\u0437\u043c\u0435\u0440 (\u0448\u0438\u0440\u0438\u043d\u0443 \u0438 \u0432\u044b\u0441\u043e\u0442\u0443) \u0432 \u043f\u0438\u0441\u043a\u0441\u0435\u043b\u044f\u0445 \u0438 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u043c\u0435\u0440\u0430 \u0434\u043b\u044f \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439 \u0432 \u043d\u0435\u0433\u043e.<\/p>\n<p>\u0414\u043b\u044f \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u0430 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439 \u0438\u0437 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a> \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u043c\u0435\u0442\u043e\u0434\u043e\u043c \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a>:<br \/><a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap#getPixels(int[],%20int,%20int,%20int,%20int,%20int,%20int)\" rel=\"noopener noreferrer nofollow\">void getPixels (int[] pixels, int offset, int stride, int x, int y, int width, int height)<\/a><\/p>\n<p>\u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043b\u0438\u043d\u0435\u0439\u043d\u044b\u0439 \u043c\u0430\u0441\u0441\u0438\u0432 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439<br \/><code>jintArray pixels = env-&gt;NewIntArray(aBitmapPixelsCount);<br \/><\/code>\u041f\u043e\u0441\u043b\u0435 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u043f\u0438\u043a\u0441\u0435\u043b\u0438 \u0431\u0443\u0434\u0443\u0442 \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u044b, \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c \u043d\u0430 \u043d\u0430\u0447\u0430\u043b\u043e \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 C++ \u043a\u043e\u0434\u0435:<br \/><code>jint *pPixels = env-&gt;GetIntArrayElements(pixels, nullptr);<\/code><br \/>\u0417\u0430\u0442\u0435\u043c \u0432 \u0446\u0438\u043a\u043b\u0435 \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439 \u0438\u0437 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u0432 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">Qimage<\/a>. \u041f\u043e \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044e \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043e\u0441\u0432\u043e\u0431\u043e\u0436\u0434\u0430\u0435\u043c \u043f\u0430\u043c\u044f\u0442\u044c, \u0432\u044b\u0434\u0435\u043b\u0435\u043d\u043d\u0443\u044e \u043f\u043e\u0434 \u043c\u0430\u0441\u0441\u0438\u0432 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439<br \/><code>env-&gt;DeleteLocalRef(pixels);<\/code><br \/>\u0438 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432 \u0432\u0438\u0434\u0435 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a>.  <\/p>\n<p>\u041e\u0442\u043b\u0438\u0447\u043d\u043e. \u041c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0430.<\/p>\n<h2>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f<\/h2>\n<p>\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u043b\u0430\u0441\u0441\u043e\u043c <a href=\"https:\/\/developer.android.com\/reference\/kotlin\/androidx\/core\/content\/FileProvider?hl=en\" rel=\"noopener noreferrer nofollow\">FileProvider<\/a>, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0440\u0430\u0437\u0434\u0435\u043b\u044f\u0435\u043c\u044b\u0439 <a href=\"https:\/\/developer.android.com\/reference\/android\/net\/Uri.html\" rel=\"noopener noreferrer nofollow\">Uri<\/a> \u0434\u043b\u044f \u0444\u0430\u0439\u043b\u0430 \u0444\u043e\u0442\u043e\u0441\u043d\u0438\u043c\u043a\u0430. \u041e\u0431\u0440\u0430\u0449\u0430\u044e \u0432\u0430\u0448\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u0443 Android, \u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435, \u0438\u0445 \u0434\u0432\u0430:<\/p>\n<ol>\n<li>\n<p>androidx.core.content.FileProvider;<\/p>\n<\/li>\n<li>\n<p>android.support.v4.content.FileProvider.<\/p>\n<\/li>\n<\/ol>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u2014 \u0441\u0430\u043c\u044b\u0439 \u0441\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0439, \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442\u0441\u044f Qt, \u0430 \u0434\u043b\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0440\u0435\u0434\u0443 QtCerator:<\/p>\n<h4>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0438<\/h4>\n<p>\u0413\u043b\u0430\u0432\u043d\u043e\u0435 \u043c\u0435\u043d\u044e (\u0441\u0432\u0435\u0440\u0445\u0443)\u2192 \u00ab\u0418\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b\u00bb \u2192    \u00ab\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b\u00bb \u2192 \u00ab\u0423\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u00bb\u2192 \u0432\u043a\u043b\u0430\u0434\u043a\u0430 \u00abAndroid\u00bb\u2192 \u0432\u043a\u043b\u0430\u0434\u043a\u0430 \u00abSDK Manager\u00bb\u2192\u0420\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0441\u043f\u0438\u0441\u043a\u0430 \u00ab\u0418\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b\u00bb \u0432 \u0441\u043f\u0438\u0441\u043e\u043a\u2192 \u00abExtras\u00bb\u2192 \u00abAndroid Support Repository\u00bb &#8212; \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0444\u043b\u0430\u0436\u043e\u043a \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0438 \u043d\u0430\u0436\u0438\u0442\u044c \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u00ab\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c\u00bb \u0441\u043f\u0440\u0430\u0432\u0430.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/821\/952\/91a\/82195291a5744da086a0ae21d9a48575.gif\" width=\"1920\" height=\"1080\"><figcaption><\/figcaption><\/figure>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/163\/147\/978\/16314797820b67ac7c689f6714fe55fa.gif\" width=\"1118\" height=\"82\"><figcaption><\/figcaption><\/figure>\n<h4>\u0417\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0430\u0432\u0442\u043e\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u0435 \u0444\u0430\u0439\u043b\u044b \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0441\u0431\u043e\u0440\u043a\u0438 \u0434\u043b\u044f Android \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c\u0438<\/h4>\n<p>\u041f\u0435\u0440\u0435\u0439\u0442\u0438 \u043d\u0430 \u0431\u043e\u043a\u043e\u0432\u043e\u0439 \u043f\u0430\u043d\u0435\u043b\u0438 QtCreator \u043d\u0430 \u0432\u043a\u043b\u0430\u0434\u043a\u0443 \u00ab\u041f\u0440\u043e\u0435\u043a\u0442\u044b\u00bb. \u0412 \u043b\u0435\u0432\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u043e\u043a\u043d\u0430 \u00ab\u0421\u0431\u043e\u0440\u043a\u0430 \u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u00bb\u2192 \u00ab\u0421\u0431\u043e\u0440\u043a\u0430\u00bb. \u0422\u043e\u0433\u0434\u0430 \u0432 \u043f\u0440\u0430\u0432\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u043e\u043a\u043d\u0430 \u00abBuild Android APK\u00bb \u2192 \u00abCreate Templates\u00bb. \u0412 \u043f\u043e\u044f\u0432\u0438\u0432\u0448\u0435\u043c\u0441\u044f \u0434\u0438\u0430\u043b\u043e\u0433\u043e\u0432\u043e\u043c \u043e\u043a\u043d\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0444\u043b\u0430\u0436\u043e\u043a \u00ab\u041a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b\u044b Gradle \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 Android\u00bb, \u043d\u0430\u0436\u0430\u0442\u044c \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u00ab\u0417\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044c\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/77c\/206\/540\/77c206540ad15c0284e77ff4ab70729f.gif\" width=\"1920\" height=\"1080\"><figcaption><\/figcaption><\/figure>\n<h4>\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u0441\u043e \u0441\u0432\u043e\u0438\u043c\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 \u0441\u0431\u043e\u0440\u043a\u0438 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442<\/h4>\n<p>\u0412 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0441 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u043c\u0438 \u043a\u043e\u0434\u0430\u043c\u0438 \u0432\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u00abandroid\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432 \u043f\u0440\u043e\u0435\u043a\u0442.<\/p>\n<h4>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0432 \u0444\u0430\u0439\u043b\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u043e\u0442\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u0443\u044e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 Android<\/h4>\n<p>\u0415\u0441\u043b\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043a\u0440\u043e\u0441\u0441-\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e\u0435 \u0438 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u044f \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 Android, \u0442\u043e \u0432 .pro \u0444\u0430\u0439\u043b\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u0443 android: \u043f\u0435\u0440\u0435\u0434 \u043a\u0430\u0436\u0434\u044b\u043c \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u043c \u0444\u0430\u0439\u043b\u043e\u043c:<\/p>\n<pre><code class=\"cpp\">android {     QT       +=androidextras } # \u2026  DISTFILES += \\ android:    android\/AndroidManifest.xml \\ android:    android\/build.gradle \\ android:    android\/gradle\/wrapper\/gradle-wrapper.jar \\ android:    android\/gradle\/wrapper\/gradle-wrapper.properties \\ android:    android\/gradlew \\ android:    android\/gradlew.bat \\ android:    android\/res\/values\/libs.xml \\     todo.txt<\/code><\/pre>\n<h4>\u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c AndroidManifest.xml<\/h4>\n<p>\u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u00abAndroidManifest.xml\u00bb \u0432 android\/AndroidManifest.xml, \u0434\u043e\u0431\u0430\u0432\u0438\u0432 \u0432 \u0441\u0435\u043a\u0446\u0438\u044e  \u043f\u043e\u0441\u043b\u0435<\/p>\n<pre><code class=\"xml\">&lt;\/activity&gt; &lt;!-- For adding service(s) please check: https:\/\/wiki.qt.io\/AndroidServices -&gt;<\/code><\/pre>\n<p>\u0442\u0435\u043a\u0441\u0442:<\/p>\n<pre><code class=\"xml\">&lt;provider android:name=\"android.support.v4.content.FileProvider\" android:authorities=\"org.qtproject.example.qsketch.fileprovider\" android:grantUriPermissions=\"true\" android:exported=\"false\"&gt; &lt;meta-data android:name=\"android.support.FILE_PROVIDER_PATHS\" android:resource=\"@xml\/file_paths\"\/&gt; &lt;\/provider&gt;<\/code><\/pre>\n<h4>\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0441 \u0443\u043a\u0430\u0437\u0430\u043d\u0438\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438<\/h4>\n<p>\u042d\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u043c\u043e\u0433\u043b\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u043d\u0430\u0448\u0435\u043c\u0443 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e \u0444\u0430\u0439\u043b.<\/p>\n<p>\u0412 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0441\u0431\u043e\u0440\u043a\u0438, \u0442\u0430\u043c \u0433\u0434\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u0439 \u0444\u0430\u0439\u043b \u00abAndroidManifest.xml\u00bb \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u00abres\u00bb \u0440\u044f\u0434\u043e\u043c \u0441 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u043e\u043c \u00abvalues\u00bb, \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u00abxml\u00bb, \u0430 \u0432 \u043d\u0451\u043c \u0444\u0430\u0439\u043b \u00abfile_paths.xml\u00bb (\u2026 \/abin\/AndroidManifest.xml) (\u2026 \/abin\/res\/xml\/file_paths.xml). \u0412 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438:<\/p>\n<pre><code class=\"xml\">&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt; &lt;paths xmlns:android=\"http:\/\/schemas.android.com\/apk\/res\/android\"&gt; &lt;external-files-path name=\"shared\" path=\"shared\/\" \/&gt; &lt;\/paths&gt;<\/code><\/pre>\n<p>\u0433\u0434\u0435 shared\/ \u0438\u043c\u044f \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0435 \u0444\u0430\u0439\u043b\u043e\u0432 \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f<\/p>\n<h4>\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 FileProvider \u0432 \u0441\u0431\u043e\u0440\u043a\u0443<\/h4>\n<p>\u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b android\/build.gradle, \u0434\u043e\u0431\u0432\u0438\u0432 \u0432 \u0441\u0435\u043a\u0446\u0438\u044e dependencies \u0442\u0435\u043a\u0441\u0442:<\/p>\n<pre><code class=\"xml\">compile'com.android.support:support-v4:25.3.1'<\/code><\/pre>\n<p>\u0441\u0435\u043a\u0446\u0438\u044f \u0446\u0435\u043b\u0438\u043a\u043e\u043c \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"xml\">dependencies { implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar']) compile'com.android.support:support-v4:25.3.1' }<\/code><\/pre>\n<p>\u0414\u0430\u043d\u043d\u0430\u044f \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0435\u0441\u043b\u0438 \u0431\u044b\u043b \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d Android Support Repository.<\/p>\n<p>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u0438\u0438 \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/www.qt.io\/blog\/2018\/11\/06\/sharing-files-android-ios-qt-app-part-4\" rel=\"noopener noreferrer nofollow\">Sharing Files on Android or iOS from or with your Qt App &#8212; Part 4<\/a> \u0438  \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u0441\u0442\u0430\u0442\u0435\u0439 \u043d\u0430 \u044d\u0442\u0443 \u0442\u0435\u043c\u0443.<\/p>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.h) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">#ifndef CAMSHOT_H #define CAMSHOT_H #include &lt;QObject&gt; #include &lt;QImage&gt; #include &lt;QString&gt; #include &lt;QDebug&gt;  #include &lt;QtAndroid&gt; #include &lt;QAndroidActivityResultReceiver&gt; #include &lt;QAndroidParcel&gt;  #include \"auxfunc.h\"  class CamShot : public QObject, public QAndroidActivityResultReceiver {     Q_OBJECT public:     static const int RESULT_OK = -1;     static const int REQUEST_IMAGE_CAPTURE = 1;     static const int REQUEST_TAKE_PHOTO = REQUEST_IMAGE_CAPTURE;     enum ImgOrientation {ORIENTATION_UNDEFINED = 0, ORIENTATION_NORMAL = 1, ORIENTATION_FLIP_HORIZONTAL = 2, ORIENTATION_ROTATE_180 = 3, ORIENTATION_FLIP_VERTICAL = 4, ORIENTATION_TRANSPOSE = 5,                        ORIENTATION_ROTATE_90 = 6, ORIENTATION_TRANSVERSE = 7, ORIENTATION_ROTATE_270 = 8};     void handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data) override;     static QImage aBitmapToQImage(const QAndroidJniObject &amp;aBitmap);     static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data);     ImgOrientation needRotateAtRightAngle();     QImage camImageToQImage();     static void applyOrientation(QImage &amp;img, const ImgOrientation &amp;orientation);       explicit CamShot(QObject *parent = nullptr):QObject(parent),QAndroidActivityResultReceiver(){}     ~CamShot(); private:         QAndroidJniObject tempImgURI;     QAndroidJniObject tempImgFile;     QAndroidJniObject tempImgAbsPath;     bool _thumbnailNotFullScaleRequested; public slots:     void aMakeShot(const bool &amp;thumbnailNotFullScale = false); signals:     void createNew(const QImage &amp;img); }; #endif \/\/ CAMSHOT_H<\/code><\/pre>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.cpp) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">QImage CamShot::aBitmapToQImage(const QAndroidJniObject &amp;aBitmap){     if (!aBitmap.isValid())         return QImage();     jint aBitmapWidth = aBitmap.callMethod&lt;jint&gt;(\"getWidth\");     jint aBitmapHeight = aBitmap.callMethod&lt;jint&gt;(\"getHeight\");     QAndroidJniEnvironment env;     const int32_t aBitmapPixelsCount = aBitmapWidth * aBitmapHeight;     jintArray pixels = env-&gt;NewIntArray(aBitmapPixelsCount);     jint aBitmapOffset = 0;     jint aBitmapStride = aBitmapWidth;     jint aBitmapX = 0;     jint aBitmapY = 0;     aBitmap.callMethod&lt;void&gt;(\"getPixels\",\"([IIIIIII)V\", pixels, aBitmapOffset, aBitmapStride, aBitmapX, aBitmapY, aBitmapWidth, aBitmapHeight);     jint *pPixels = env-&gt;GetIntArrayElements(pixels, nullptr);     QImage img(aBitmapWidth, aBitmapHeight, QImage::Format_ARGB32);     int lineSzB = aBitmapWidth * sizeof(jint);     for (int i = 0; i &lt; aBitmapHeight; ++i){         uchar *pDst = img.scanLine(i);         const uchar *pSrc = reinterpret_cast&lt;const uchar*&gt;(pPixels + aBitmapWidth * i + aBitmapWidth);         memcpy(pDst, pSrc, lineSzB);     }     env-&gt;DeleteLocalRef(pixels); \/\/env-&gt;ReleaseIntArrayElements(pixels, pPixels, 0); \u043e\u0442\u0432\u044f\u0437\u044b\u0432\u0430\u0435\u0442 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c \u043d\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u043e\u0442 \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u0430 \u043d\u0430\u0434\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0441\u0430\u043c \u043c\u0430\u0441\u0441\u0438\u0432, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 DeleteLocalRef.     return img; } QImage CamShot::camThumbnailToQImage(const QAndroidJniObject &amp;data){     \/\/\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0434\u0430\u043d\u043d\u044b\u0435     QAndroidJniObject bundle = data.callObjectMethod(\"getExtras\",\"()Landroid\/os\/Bundle;\");     qDebug()&lt;&lt;\"bundle.isValid() \"&lt;&lt;bundle.isValid()&lt;&lt;bundle.toString();     \/\/\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442 \u0442\u0438\u043f\u0430 jstring (\u0441\u0442\u0440\u043e\u043a\u0430 Java) \u0441\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \"data\" - \u043a\u043b\u044e\u0447 \u0434\u043b\u044f \u0438\u0437\u0432\u043b\u0435\u0447\u0435\u043d\u0438\u044f \u0438\u0437 \u0430\u0441\u0441\u043e\u0446\u0438\u0430\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u043f\u0430\u0440 &lt;\u043a\u043b\u044e\u0447, \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435&gt; \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b - \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u0442\u0438\u043f\u0430 Bitmap (Java)     QAndroidJniObject bundleKey = QAndroidJniObject::fromString(\"data\");     \/\/\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043f\u043e \u043a\u043b\u044e\u0447\u0443 \"data\" \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0434\u0430\u043d\u043d\u044b\u0435: \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u0432 \u0432\u0438\u0434\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 Bitmap     const QAndroidJniObject aBitmap (data.callObjectMethod(\"getParcelableExtra\", \"(Ljava\/lang\/String;)Landroid\/os\/Parcelable;\", bundleKey.object&lt;jstring&gt;()));     qDebug()&lt;&lt;\"aBitmap.isValid() \"&lt;&lt;aBitmap.isValid()&lt;&lt;aBitmap.toString();     return aBitmapToQImage(aBitmap); } QImage CamShot::camImageToQImage(){     QAndroidJniObject bitmap = QAndroidJniObject::callStaticObjectMethod(\"android\/graphics\/BitmapFactory\",\"decodeFile\",\"(Ljava\/lang\/String;)Landroid\/graphics\/Bitmap;\",tempImgAbsPath.object&lt;jobject&gt;());     qDebug()&lt;&lt;\"bitmap.isValid() \"&lt;&lt;bitmap.isValid()&lt;&lt;bitmap.toString();     QImage img = aBitmapToQImage(bitmap);     \/\/\u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430     if (tempImgFile.isValid())         tempImgFile.callMethod&lt;jboolean&gt;(\"delete\");     return img; } CamShot::ImgOrientation CamShot::needRotateAtRightAngle(){     \/\/\u0412\u044b\u0437\u043e\u0432 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0430     QAndroidJniObject exifInterface = QAndroidJniObject(\"android\/media\/ExifInterface\",\"(Ljava\/lang\/String;)V\",                                                      tempImgAbsPath.object&lt;jstring&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"exifInterface.isValid()=\" &lt;&lt; exifInterface.isValid();     QAndroidJniObject TAG_ORIENTATION = QAndroidJniObject::getStaticObjectField&lt;jstring&gt;(\"android\/media\/ExifInterface\", \"TAG_ORIENTATION\");     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"TAG_ORIENTATION.isValid()=\" &lt;&lt; TAG_ORIENTATION.isValid()&lt;&lt;TAG_ORIENTATION.toString();     const jint orientation = exifInterface.callMethod&lt;jint&gt;(\"getAttributeInt\",\"(Ljava\/lang\/String;I)I\",TAG_ORIENTATION.object&lt;jstring&gt;(),static_cast&lt;jint&gt;(ORIENTATION_UNDEFINED));     return static_cast&lt;ImgOrientation&gt;(orientation); } void CamShot::applyOrientation(QImage &amp;img, const ImgOrientation &amp;orientation){     switch (orientation){     case ORIENTATION_UNDEFINED:     case ORIENTATION_NORMAL:         break;     case ORIENTATION_FLIP_HORIZONTAL:{         img = img.mirrored(true, false);         break;     }     case ORIENTATION_ROTATE_180:         Aux::rotateImgCW180(img);         break;     case ORIENTATION_FLIP_VERTICAL:{         img = img.mirrored(false, true);         break;     }     case ORIENTATION_TRANSPOSE:{         img = img.mirrored(true, false);         Aux::rotateImgCW270(img);         break;     }     case ORIENTATION_ROTATE_90:         Aux::rotateImgCW90(img);         break;     case ORIENTATION_TRANSVERSE:{         img = img.mirrored(true, false);         Aux::rotateImgCW90(img);         break;     }         break;     case ORIENTATION_ROTATE_270:         Aux::rotateImgCW270(img);         break;     } } void CamShot::handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data){     if ( receiverRequestCode == REQUEST_IMAGE_CAPTURE &amp;&amp; resultCode == RESULT_OK )     {         if (_thumbnailNotFullScaleRequested){             const QImage thumbnail (camThumbnailToQImage(data));             if (!thumbnail.isNull())                 emit createNew(thumbnail);             return;         }         const ImgOrientation orientation = needRotateAtRightAngle();         QImage image (camImageToQImage());         if (!image.isNull()){             applyOrientation(image, orientation);             emit createNew(image);         }     } } void CamShot::aMakeShot(const bool &amp;thumbnailNotFullScale) {     QAndroidJniObject action = QAndroidJniObject::fromString(\"android.media.action.IMAGE_CAPTURE\");     \/\/\u0412\u044b\u0437\u043e\u0432 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0430     QAndroidJniObject intent=QAndroidJniObject(\"android\/content\/Intent\",\"(Ljava\/lang\/String;)V\",                                                  action.object&lt;jstring&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"intent.isValid()=\" &lt;&lt; intent.isValid();     _thumbnailNotFullScaleRequested = thumbnailNotFullScale;     if (thumbnailNotFullScale) {         \/\/\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b         QtAndroid::startActivity(intent, REQUEST_IMAGE_CAPTURE, this);         return;     }     \/\/\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432 \u0444\u0430\u0439\u043b     QAndroidJniObject context = QtAndroid::androidContext();     QString contextStr (context.toString());     qDebug() &lt;&lt;\"Context: \"&lt;&lt;contextStr;     \/\/\u041a\u0430\u0442\u0430\u043b\u043e\u0433 \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f     QAndroidJniObject extDir = context.callObjectMethod(\"getExternalFilesDir\", \"(Ljava\/lang\/String;)Ljava\/io\/File;\", NULL);     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"extDir.isValid()=\" &lt;&lt; extDir.isValid()&lt;&lt;extDir.toString();     \/\/\u0410\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0443 \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438     QAndroidJniObject extDirAbsPath = extDir.callObjectMethod(\"getAbsolutePath\",\"()Ljava\/lang\/String;\");     \/\/\u0414\u043e\u0431\u0430\u0432\u0438\u043c \u0438\u043c\u044f \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u0434\u043b\u044f \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u044d\u0442\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438. \u0421\u043c. \/res\/xml\/file_paths.xml     extDirAbsPath = QAndroidJniObject::fromString(extDirAbsPath.toString() + \"\/shared\");     const QString extDirAbsPathStr = extDirAbsPath.toString();     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"extDirAbsPath.isValid()=\" &lt;&lt; extDirAbsPath.isValid()&lt;&lt;extDirAbsPathStr;     \/\/\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442 \u0442\u0438\u043f\u0430 \u0424\u0430\u0439\u043b \u0434\u043b\u044f \u0440\u0430\u0437\u0434\u0435\u043b\u044f\u0435\u043c\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430     QAndroidJniObject sharedFolder=QAndroidJniObject(\"java.io.File\",\"(Ljava\/lang\/String;)V\",                                                       extDirAbsPath.object&lt;jstring&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"sharedFolder.isValid()=\" &lt;&lt; sharedFolder.isValid()&lt;&lt;sharedFolder.toString();     const jboolean sharedFolderCreated = sharedFolder.callMethod&lt;jboolean&gt;(\"mkdirs\");     Q_UNUSED(sharedFolderCreated);     \/\/\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u044b\u0442\u0430\u0442\u044c\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0441 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c, \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0444\u0430\u0439\u043b \u0441 \u044d\u0442\u0438\u043c \u0438\u043c\u0435\u043d\u0435\u043c \u043d\u0430 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u043d\u0438\u0435     \/\/\u041f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0443\u0442\u044c \u043a \u044d\u0442\u043e\u043c\u0443 \u0444\u0430\u0439\u043b\u0443     QAndroidJniObject suggestedFilePath = QAndroidJniObject::fromString(extDirAbsPathStr+\"\/\"+\"_tmp.jpg\");     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"suggestedFilePath.isValid()=\" &lt;&lt; suggestedFilePath.isValid()&lt;&lt;suggestedFilePath.toString();     \/\/\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442 \u0442\u0438\u043f\u0430 \u0424\u0430\u0439\u043b     \/\/\u0412\u044b\u0437\u043e\u0432 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0430     QAndroidJniObject tempImgFile=QAndroidJniObject(\"java.io.File\",\"(Ljava\/lang\/String;)V\",                                                  suggestedFilePath.object&lt;jstring&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"fileExistsCheck.isValid()=\" &lt;&lt; tempImgFile.isValid()&lt;&lt;tempImgFile.toString();     \/\/\u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430, \u0435\u0441\u043b\u0438 \u043e\u043d \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442     if (tempImgFile.isValid()){         const jboolean deleted = tempImgFile.callMethod&lt;jboolean&gt;(\"delete\");         Q_UNUSED(deleted);     }     \/\/\u0421\u043e\u0437\u0434\u0430\u0442\u044c \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u0437\u0430\u043f\u0438\u0441\u0438 \u0432 \u043d\u0435\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043f\u043e \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c\u0443 \u043f\u0443\u0442\u0438     const jboolean fileCreated = tempImgFile.callMethod&lt;jboolean&gt;(\"createNewFile\");     Q_UNUSED(fileCreated);     \/\/\u0410\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u043c\u0443 \u0444\u0430\u0439\u043b\u0443 \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438     tempImgAbsPath = tempImgFile.callObjectMethod(\"getAbsolutePath\",\"()Ljava\/lang\/String;\");     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"tempImgAbsPath.isValid()=\" &lt;&lt; tempImgAbsPath.isValid()&lt;&lt;tempImgAbsPath.toString();     \/\/\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c authority \u0434\u043b\u044f fileprovider     const QString contextFileProviderStr (\"org.qtproject.example.qsketch.fileprovider\");     const char androidFileProvider  [] = \"android\/support\/v4\/content\/FileProvider\";     \/\/const char androidxFileProvider [] = \"androidx\/core\/content\/FileProvider\"; - \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442\u0441\u044f Qt     \/*QAndroidJniObject*\/ tempImgURI = QAndroidJniObject::callStaticObjectMethod(androidFileProvider, \"getUriForFile\", \"(Landroid\/content\/Context;Ljava\/lang\/String;Ljava\/io\/File;)Landroid\/net\/Uri;\",                                                                              context.object&lt;jobject&gt;(), QAndroidJniObject::fromString(contextFileProviderStr).object&lt;jstring&gt;(), tempImgFile.object&lt;jobject&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"tempImgURI.isValid()=\" &lt;&lt; tempImgURI.isValid()&lt;&lt;tempImgURI.toString();     \/\/\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u044b MediaStore.EXTRA_OUTPUT     QAndroidJniObject MediaStore__EXTRA_OUTPUT         = QAndroidJniObject::getStaticObjectField(\"android\/provider\/MediaStore\", \"EXTRA_OUTPUT\", \"Ljava\/lang\/String;\");     qDebug() &lt;&lt; \"MediaStore__EXTRA_OUTPUT.isValid()=\" &lt;&lt; MediaStore__EXTRA_OUTPUT.isValid();     \/\/\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c URI \u043f\u0443\u0442\u044c \u0444\u0430\u0439\u043b\u0430 \u0434\u043b\u044f \u0437\u0430\u043f\u0438\u0441\u0438 \u0432 \u043d\u0435\u0433\u043e \u0434\u0430\u043d\u043d\u044b\u0445 \u043a \u0437\u0430\u0434\u0430\u0447\u0435     intent.callObjectMethod(\"putExtra\",\"(Ljava\/lang\/String;Landroid\/os\/Parcelable;)Landroid\/content\/Intent;\",MediaStore__EXTRA_OUTPUT.object&lt;jstring&gt;(), tempImgURI.object&lt;jobject&gt;());     qDebug() &lt;&lt; __FUNCTION__ &lt;&lt; \"intent.isValid()=\" &lt;&lt; intent.isValid();     QtAndroid::startActivity(intent, REQUEST_IMAGE_CAPTURE, this); }<\/code><\/pre>\n<p>\u0422\u0430\u043a-\u0436\u0435 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043c\u0435\u0442\u043e\u0434\u044b \u043a\u043b\u0430\u0441\u0441\u0430 <strong>Aux<\/strong> \u0434\u043b\u044f \u043f\u043e\u0432\u043e\u0440\u043e\u0442\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f.<\/p>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.h) \u043a\u043b\u0430\u0441\u0441\u0430 <strong>Aux <\/strong>\u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">#ifndef AUXFUNC_H #define AUXFUNC_H  #include &lt;QImage&gt; #include &lt;QColor&gt; #include &lt;QPainter&gt; #include &lt;QMatrix&gt; #include &lt;QSize&gt; #include &lt;QPoint&gt;  class Aux { public:     static void resizeCenteredImg(QImage *image, const QSize &amp;newSize, const QColor bgColor);     static void rotateImg(QImage &amp;img, qreal degrees);     static void rotateImgCW90(QImage &amp;img);     static void rotateImgCW180(QImage &amp;img);     static void rotateImgCW270(QImage &amp;img); };   #endif \/\/ AUXFUNC_H<\/code><\/pre>\n<p>\u0424\u0430\u0439\u043b \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430 (.cpp) \u043a\u043b\u0430\u0441\u0441\u0430 <strong>Aux <\/strong>\u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">void Aux::resizeCenteredImg(QImage *image, const QSize &amp;newSize, const QColor bgColor){     if (image-&gt;size() == newSize)         return;     const QSize szDiff = newSize - image-&gt;size();     QImage newImage(newSize, QImage::Format_ARGB32);     newImage.fill(bgColor);     QPainter painter(&amp;newImage);     painter.drawImage(QPoint(szDiff.width()\/2, szDiff.height()\/2), *image);     *image = newImage; } void Aux::rotateImg(QImage &amp;img, qreal degrees){     QPoint center = img.rect().center();     QMatrix matrix;     matrix.translate(center.x(), center.y());     matrix.rotate(degrees);     img = img.transformed(matrix, Qt::SmoothTransformation); } void Aux::rotateImgCW90(QImage &amp;img){     const int w = img.width();     const int h = img.height();     const int maxDim = std::max(w, h);     resizeCenteredImg(&amp;img, QSize(maxDim, maxDim), Qt::white);     rotateImg(img, 90);     resizeCenteredImg(&amp;img, QSize(h, w), Qt::white); } void Aux::rotateImgCW180(QImage &amp;img){     rotateImg(img, 180); } void Aux::rotateImgCW270(QImage &amp;img){     const int w = img.width();     const int h = img.height();     const int maxDim = std::max(w, h);     resizeCenteredImg(&amp;img, QSize(maxDim, maxDim), Qt::white);     rotateImg(img, 270);     resizeCenteredImg(&amp;img, QSize(h, w), Qt::white); }<\/code><\/pre>\n<p>\u0423\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0437\u0430 \u043e\u0434\u0438\u043d \u0440\u0430\u0437 \u0438\u043b\u0438 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u0438\u043b\u0438 \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435.<\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 \u00ab<strong>thumbnailNotFullScale<\/strong>\u00bb. \u0415\u0441\u043b\u0438 \u043e\u043d \u0440\u0430\u0432\u0435\u043d \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0435\u0434\u0438\u043d\u0438\u0446\u0435, \u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0430 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0430, \u0435\u0441\u043b\u0438 \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u043c\u0443 \u043d\u0443\u043b\u044e, \u0442\u043e \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435. \u041f\u043e\u043f\u044b\u0442\u043a\u0430 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u043f\u0440\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0435 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432 \u0444\u0430\u0439\u043b \u043f\u0440\u0438\u0432\u0435\u0434\u0451\u0442 \u043a \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044e \u0432 JNI-\u0432\u044b\u0437\u043e\u0432\u0430\u0445.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0430 \u0432\u0441\u0435\u0433\u0434\u0430 \u043e\u0440\u0438\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0430 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e, \u0442\u043e \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u043e \u0432 \u043e\u0434\u043d\u0443 \u0441\u0442\u0440\u043e\u043d\u0443 \u0438 \u0435\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u043e\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0442\u044c. \u0418\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0445 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f\u0445 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u0437 exif-\u0441\u0432\u043e\u0439\u0441\u0442\u0432 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 <a href=\"https:\/\/developer.android.com\/reference\/android\/media\/ExifInterface\" rel=\"noopener noreferrer nofollow\">ExifInterface<\/a>. \u0412 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u043d\u044b\u0445 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 <a href=\"https:\/\/stackoverflow.com\/questions\/14066038\/why-does-an-image-captured-using-camera-intent-gets-rotated-on-some-devices-on-a\" rel=\"noopener noreferrer nofollow\">Java-\u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445<\/a> \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043a \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e\u0439 \u043e\u0440\u0438\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0432 Java-\u043a\u043e\u0434\u0435, \u0432 \u0441\u043b\u0443\u0447\u0430\u0435 \u0441 Qt \u043d\u0435\u0442 \u0441\u043c\u044b\u0441\u043b\u0430 \u043c\u0443\u0447\u0438\u0442\u044c \u0441\u0435\u0431\u044f \u0442\u0440\u0443\u0434\u043d\u043e \u043e\u0442\u043b\u0430\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u043c\u0438, \u0433\u0440\u043e\u043c\u043e\u0437\u0434\u043a\u0438\u043c\u0438 JNI-\u0432\u044b\u0437\u043e\u0432\u0430\u043c\u0438 \u0438 \u043f\u0440\u043e\u0449\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0432\u0441\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0432 Qt.<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/544614\/\"> https:\/\/habr.com\/ru\/post\/544614\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text_v2\" id=\"post-content-body\">\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0447\u0438\u0442\u0430\u0442\u044c \u0438\u043b\u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u0430, \u043e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0432 \u043a\u043e\u043d\u0446\u0435 \u0441\u0442\u0430\u0442\u044c\u0438.<\/p>\n<h2>\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b<\/h2>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u0438\u0448\u0435\u0442\u0435 \u043a\u0440\u043e\u0441\u0441-\u043f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0435\u043d\u043d\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0442\u043e \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b \u0434\u043b\u044f \u041f\u041a \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u043b\u0430\u0441\u0441\u043e\u043c <a href=\"https:\/\/doc.qt.io\/qt-5\/qcamera.html\" rel=\"noopener noreferrer nofollow\"><strong>QCamera<\/strong><\/a>, <a href=\"https:\/\/doc.qt.io\/qt-5\/qtmultimedia-multimediawidgets-camera-example.html\" rel=\"noopener noreferrer nofollow\">\u043f\u0440\u0438\u043c\u0435\u0440<\/a> \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043e\u043f\u0438\u0441\u0430\u043d \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Qt.<\/p>\n<p>\u0412 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u043c \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0432 .pro \u0444\u0430\u0439\u043b <\/p>\n<p><code>QT += multimedia multimediawidgets<\/code> <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u0432\u0438\u0434\u0436\u0435\u0442 \u0432 \u0441\u0432\u043e\u0435\u0439 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u044e\u0449\u0438\u0439 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0438\u0437 \u0432\u0435\u0431-\u043a\u0430\u043c\u0435\u0440\u044b \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u044e\u0449\u0438\u0439 \u0435\u0433\u043e \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qpixmap.html\" rel=\"noopener noreferrer nofollow\">QPixmap<\/a> \u0438\u043b\u0438 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a> \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u0437\u0430\u0434\u0430\u0447\u0430 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u043e-\u0436\u0435 \u0441\u0430\u043c\u043e\u0435 \u043d\u0430 Android, \u0442\u043e \u0432\u044b\u044f\u0441\u043d\u044f\u0435\u0442\u0441\u044f, \u0447\u0442\u043e <strong>multimediawidgets <\/strong>\u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0434\u0430\u043d\u043d\u043e\u0439 \u041e\u0421 \u0438 \u043a\u0430\u043c\u0435\u0440\u0430 \u0441\u043d\u0438\u043c\u0430\u0442\u044c \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0442\u044c \u0441\u043d\u0438\u043c\u043a\u0438 \u0431\u0443\u0434\u0435\u0442, \u043d\u043e \u0447\u0442\u043e \u043e\u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0432 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u0433\u0430\u0434\u043a\u043e\u0439, \u0442.&nbsp;\u043a. <a href=\"https:\/\/doc.qt.io\/qt-5\/qcameraviewfinder.html\" rel=\"noopener noreferrer nofollow\"><strong>QCameraViewfinder<\/strong><\/a> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 <strong>multimediawidgets <\/strong>\u0438 \u043d\u0430 Android \u043d\u0435 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u043d\u0438\u0447\u0435\u0433\u043e. \u0414\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0438\u0439 \u043f\u043e\u0438\u0441\u043a \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0434\u0432\u0443\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430\u043c \u0440\u0435\u0448\u0435\u043d\u0438\u044f:<\/p>\n<ol>\n<li>\n<p>\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0439 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtquickcontrols-index.html\" rel=\"noopener noreferrer nofollow\">Qt Quick-\u044d\u043b\u0435\u043c\u0435\u043d\u0442<\/a>, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0439 \u044d\u0442\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u0437\u0430\u0442\u0435\u043c \u0441\u043e\u0441\u0442\u044b\u043a\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u044c\u044e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043d\u0430 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtwidgets-index.html\" rel=\"noopener noreferrer nofollow\">Qt Widgets<\/a>, \u0421++;<\/p>\n<\/li>\n<li>\n<p>\u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438, \u0437\u0430\u0442\u0435\u043c \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0435\u0451 \u0432 \u0441\u0432\u043e\u0451\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438.<\/p>\n<\/li>\n<\/ol>\n<h3>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043f\u0435\u0440\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442<\/h3>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0421++ \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0441\u0442 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtwidgets-index.html\" rel=\"noopener noreferrer nofollow\">Qt Widgets<\/a>, \u0442\u043e \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0435 \u044d\u043f\u0438\u0437\u043e\u0434\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u0433\u043b\u0443\u0431\u043b\u0435\u043d\u0438\u0435 \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u0437\u0430\u0439\u043c\u0451\u0442 \u0443 \u0432\u0430\u0441 \u0432\u0440\u0435\u043c\u044f, \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043a \u044d\u0442\u043e\u043c\u0443 \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtquickcontrols-index.html\" rel=\"noopener noreferrer nofollow\">Qt Quick-\u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430<\/a>, \u0441\u0442\u044b\u043a\u043e\u0432\u043a\u0438 \u044d\u0442\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0441 \u0421++ \u043a\u043e\u0434\u043e\u043c, \u043e\u0442\u043b\u0430\u0434\u043a\u0438 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430. \u0415\u0441\u043b\u0438 \u0432\u044b \u043d\u0435 \u043f\u0440\u043e\u0444\u0435\u0441\u0441\u0438\u043e\u043d\u0430\u043b \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtqml-index.html\" rel=\"noopener noreferrer nofollow\">QML<\/a> \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u0434\u043e\u043b\u0433\u043e \u0438 \u0441\u043b\u043e\u0436\u043d\u043e.<\/p>\n<h3>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442<\/h3>\n<p>\u0412 Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0435 \u0443\u0436\u0435 \u0435\u0441\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0435\u0435 \u043d\u0443\u0436\u043d\u0443\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u043d\u0443\u0436\u043d\u043e \u0438\u043c \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f, \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0432 Java-\u0432\u044b\u0437\u043e\u0432\u044b (<a href=\"https:\/\/ru.wikipedia.org\/wiki\/Java_Native_Interface\" rel=\"noopener noreferrer nofollow\">JNI \u2014 Java Native Interface<\/a>) \u0438\u0437 \u0421++ \u043a\u043e\u0434\u0430 \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 <a href=\"https:\/\/doc.qt.io\/qt-5\/qtandroid.html\" rel=\"noopener noreferrer nofollow\"><strong>QtAndroid<\/strong><\/a>. \u0412\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u043e\u0449\u0435. \u041f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0435\u0433\u043e \u043a\u043e\u0434\u0430 \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u044f \u043d\u0435 \u043d\u0430\u0448\u0451\u043b, \u0438, \u0438\u0437\u0443\u0447\u0438\u0432 \u043e\u043f\u044b\u0442 \u0434\u0440\u0443\u0433\u0438\u0445, \u043e\u043f\u0438\u0440\u0430\u044f\u0441\u044c \u043d\u0430 <a href=\"https:\/\/developer.android.com\/reference\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u043a\u0430 \u043d\u0430 Android<\/a> \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439.<\/p>\n<h2>\u041a\u0430\u043a \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c<\/h2>\n<p>\u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0447\u0438\u0442\u0430\u0442\u044c \u0438\u043b\u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u0430, \u043e\u043a\u043e\u043d\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u043d\u043e\u0440\u0430\u0437\u043c\u0435\u0440\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438\u0437 \u043a\u0430\u043c\u0435\u0440\u044b Android-\u0441\u043c\u0430\u0440\u0442\u0444\u043e\u043d\u0430 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0432 \u043a\u043e\u043d\u0446\u0435 \u0441\u0442\u0430\u0442\u044c\u0438.<\/p>\n<p>\u041f\u0440\u043e\u0447\u0438\u0442\u0430\u0432 \u0441\u0442\u0430\u0442\u044c\u044e <a href=\"https:\/\/developer.android.com\/training\/camera\/photobasics\" rel=\"noopener noreferrer nofollow\">\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438 \u043d\u0430 Android<\/a> \u044f \u0441\u0434\u0435\u043b\u0430\u043b \u0432\u044b\u0432\u043e\u0434, \u0447\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0432 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u043b\u0438 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432 \u0432\u0438\u0434\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439 \u0438\u043b\u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0432 \u0444\u0430\u0439\u043b. \u041f\u043e\u0438\u0441\u043a\u0430\u0432 \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f, \u044f \u043d\u0430\u0448\u0451\u043b \u043d\u0430 <a href=\"https:\/\/github.com\/minixxie\/examples\/blob\/master\/qt-for-mobile\/TestExternalAndroidCamera1\/MyController.cpp\" rel=\"noopener noreferrer nofollow\">GitHub \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0438\u0439 \u043a\u043e\u0434<\/a>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u043b \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u043c\u043d\u0435 \u0437\u0430\u0434\u0430\u0447\u0443. \u041f\u0440\u0438 \u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0435, \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043e\u043d \u0443\u0441\u0442\u0430\u0440\u0435\u043b \u0438 \u0442\u0435\u043f\u0435\u0440\u044c \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a <a href=\"https:\/\/developer.android.com\/reference\/android\/os\/FileUriExposedException\" rel=\"noopener noreferrer nofollow\">FileUriExposedException<\/a> \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044e, \u043f\u0440\u0438\u0447\u0438\u043d\u044b \u0432\u043e\u0437\u043d\u0438\u043a\u043d\u043e\u0432\u0435\u043d\u0438\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u044b \u0432 \u0432\u044b\u0448\u0435\u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0435 \u043d\u0430 \u0441\u0442\u0430\u0442\u044c\u044e.<\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u0427\u0442\u043e\u0431\u044b \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e, \u043a\u0430\u043a \u043e\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043d\u0430\u0447\u043d\u0451\u043c \u0441 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0437\u0430\u0434\u0430\u0447\u0438, \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u044e\u0449\u0435\u0439 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u044f \u043a \u0444\u0430\u0439\u043b\u0430\u043c \u0438 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0430 Java-\u0432\u044b\u0437\u043e\u0432\u043e\u0432 \u2014 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b.<\/p>\n<h3>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b<\/h3>\n<p>\u041d\u0430\u0447\u043d\u0451\u043c \u0441 .pro \u0444\u0430\u0439\u043b\u0430.  <\/p>\n<p>\u041e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0434\u043b\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438 Android.<\/p>\n<pre><code>android {     QT       +=androidextras }<\/code><\/pre>\n<p>\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u043a\u043b\u0430\u0441\u0441, \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043e\u0442 <a href=\"https:\/\/doc.qt.io\/qt-5\/qandroidactivityresultreceiver.html\" rel=\"noopener noreferrer nofollow\">QAndroidActivityResultReceiver<\/a>. \u0415\u0441\u043b\u0438 \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u044a\u0435\u043a\u0442 \u043d\u0430\u0448\u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432\u044b\u0441\u044b\u043b\u0430\u043b \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 \u0441\u0438\u0433\u043d\u0430\u043b\u0430, \u0442\u043e \u043e\u043d \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d \u043e\u0442 \u043b\u044e\u0431\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 Qt, \u0438\u043c\u0435\u044e\u0449\u0435\u0433\u043e \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 <a href=\"https:\/\/doc.qt.io\/qt-5\/qobject.html\" rel=\"noopener noreferrer nofollow\">QObject<\/a>. <\/p>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.h) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">#ifndef CAMSHOT_H #define CAMSHOT_H #include &lt;QObject&gt; #include &lt;QString&gt; #include &lt;cstring&gt; #include &lt;QImage&gt; #include &lt;QDebug&gt; #include &lt;QtAndroid&gt; #include &lt;QAndroidActivityResultReceiver&gt; #include &lt;QAndroidParcel&gt; class CamShot : public QObject, public QAndroidActivityResultReceiver {     Q_OBJECT public:     CamShot(QObject *parent = nullptr):QObject(parent),QAndroidActivityResultReceiver(){}          static const int RESULT_OK = -1;      static const int REQUEST_IMAGE_CAPTURE = 1;     static const int REQUEST_TAKE_PHOTO = REQUEST_IMAGE_CAPTURE;     void handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data)  override;     static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data); public slots:     void aMakeShot(); signals:     void createNew(const QImage &amp;img); };  #endif \/\/ CAMSHOT_H<\/code><\/pre>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0439 \u0444\u0430\u0439\u043b (.cpp) \u043a\u043b\u0430\u0441\u0441\u0430 \u0438\u043c\u0435\u0435\u0442 \u0432\u0438\u0434:<\/p>\n<pre><code class=\"cpp\">QImage CamShot::camThumbnailToQImage(const QAndroidJniObject &amp;data){     QAndroidJniObject bundle = data.callObjectMethod(\"getExtras\",\"()Landroid\/os\/Bundle;\");     qDebug()&lt;&lt;\"bundle.isValid() \"&lt;&lt;bundle.isValid()&lt;&lt;bundle.toString();     QAndroidJniObject bundleKey = QAndroidJniObject::fromString(\"data\");     const QAndroidJniObject aBitmap (data.callObjectMethod(\"getParcelableExtra\", \"(Ljava\/lang\/String;)Landroid\/os\/Parcelable;\", bundleKey.object&lt;jstring&gt;()));     qDebug()&lt;&lt;\"aBitmap.isValid() \"&lt;&lt;aBitmap.isValid()&lt;&lt;aBitmap.toString();     jint aBitmapWidth = aBitmap.callMethod&lt;jint&gt;(\"getWidth\");     jint aBitmapHeight = aBitmap.callMethod&lt;jint&gt;(\"getHeight\");     QAndroidJniEnvironment env;     const int32_t aBitmapPixelsCount = aBitmapWidth * aBitmapHeight;     jintArray pixels = env-&gt;NewIntArray(aBitmapPixelsCount);     jint aBitmapOffset = 0;     jint aBitmapStride = aBitmapWidth;     jint aBitmapX = 0;     jint aBitmapY = 0;     aBitmap.callMethod&lt;void&gt;(\"getPixels\",\"([IIIIIII)V\", pixels, aBitmapOffset, aBitmapStride, aBitmapX, aBitmapY, aBitmapWidth, aBitmapHeight);     jint *pPixels = env-&gt;GetIntArrayElements(pixels, nullptr);     QImage img(aBitmapWidth, aBitmapHeight, QImage::Format_ARGB32);     int lineSzB = aBitmapWidth * sizeof(jint);     for (int i = 0; i &lt; aBitmapHeight; ++i){         uchar *pDst = img.scanLine(i);         const uchar *pSrc = reinterpret_cast&lt;const uchar*&gt;(pPixels + aBitmapWidth * i + aBitmapWidth);         memcpy(pDst, pSrc, lineSzB);     }     env-&gt;DeleteLocalRef(pixels); \/\/env-&gt;ReleaseIntArrayElements(pixels, pPixels, 0); \u043e\u0442\u0432\u044f\u0437\u044b\u0432\u0430\u0435\u0442 \u0443\u043a\u0430\u0437\u0430\u0442\u0435\u043b\u044c \u043d\u0430 \u0434\u0430\u043d\u043d\u044b\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u043e\u0442 \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u0430 \u043d\u0430\u0434\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0441\u0430\u043c \u043c\u0430\u0441\u0441\u0438\u0432, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 DeleteLocalRef.      return img; } void CamShot::aMakeShot() {     QAndroidJniObject action = QandroidJniObject::fromString(\"android.media.action.IMAGE_CAPTURE\");     \/\/\u0415\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c Java-\u043a\u043b\u0430\u0441\u0441 (\u043d\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438), \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u043d\u043e\u0435 \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442\u043e\u0447\u043a\u0438-\u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430 \"\/\"), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440  \"android\/content\/Intent\", \"java\/lang\/String\".     \/\/\u0415\u0441\u043b\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 Java-\u043e\u0431\u044a\u0435\u043a\u0442, \u0442\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 \"L\" \u0438 \";\" \u0432 \u043a\u043e\u043d\u0446\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \"Landroid\/content\/Intent ;\", \"Ljava\/lang\/String;\".     \/\/\u0415\u0441\u043b\u0438 \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0439 \u0442\u0438\u043f \u0438\u043b\u0438 \u043c\u0430\u0441\u0441\u0438\u0432, \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0431\u0435\u0437 \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0435\u0439, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \"V\" (void) \u0438\u043b\u0438 \"[IIIIIII\" (\u043c\u0430\u0441\u0441\u0438\u0432 jint, \u0438 6 jint \u0437\u0430 \u043d\u0438\u043c)     \/\/\u0421\u0438\u043c\u0432\u043e\u043b\u044b, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u044f \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b \u0442\u0438\u043f\u0430\u043c:     QAndroidJniObject intent=QAndroidJniObject(\"android\/content\/Intent\",\"(Ljava\/lang\/String;)V\", action.object&lt;jstring&gt;());     QtAndroid::startActivity(intent, REQUEST_IMAGE_CAPTURE, this); } void CamShot::handleActivityResult(int receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data){     if ( receiverRequestCode == REQUEST_IMAGE_CAPTURE &amp;&amp; resultCode == RESULT_OK )     {         const QImage thumbnail (camThumbnailToQImage(data));         if (!thumbnail.isNull())             emit createNew(thumbnail);     } }<\/code><\/pre>\n<h4>\u0420\u0430\u0437\u0431\u0435\u0440\u0451\u043c \u043f\u0440\u0438\u0432\u0435\u0434\u0451\u043d\u043d\u044b\u0439 \u043a\u043e\u0434<\/h4>\n<h4>\u041a\u0440\u0430\u0442\u043a\u0438\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0443\u043a\u0430\u0437\u0430\u043d\u0438\u044f \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 JNI-\u0432\u044b\u0437\u043e\u0432\u0430\u0445<\/h4>\n<ol>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0438\u043c\u044f Java-\u043a\u043b\u0430\u0441\u0441\u0430 (\u043d\u0435 \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 Java-\u0444\u0443\u043d\u043a\u0446\u0438\u0438), \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u043b\u043d\u043e\u0435 \u0438\u043c\u044f \u043a\u043b\u0430\u0441\u0441\u0430 (\u0442\u043e\u0447\u043a\u0438-\u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430 &#171;<strong>\/<\/strong>&#171;), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>android\/content\/Intent<\/strong>&#171;, &#171;<strong>java\/lang\/String<\/strong>&#171;;<\/p>\n<\/li>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 Java-\u043e\u0431\u044a\u0435\u043a\u0442, \u0442\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0438\u043c\u044f \u0435\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 &#171;<strong>L<\/strong>&#187; \u0438 &#171;<strong>;<\/strong>&#187; \u0432 \u043a\u043e\u043d\u0446\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>Landroid\/content\/Intent;<\/strong>&#171;, &#171;<strong>Ljava\/lang\/String;<\/strong>&#171;;<\/p>\n<\/li>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0439 \u0442\u0438\u043f \u0438\u043b\u0438 \u043c\u0430\u0441\u0441\u0438\u0432, \u0442\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b (\u0441\u0438\u043c\u0432\u043e\u043b\u044b \u0431\u0435\u0437 \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u0435\u0439), \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &#171;<strong>V<\/strong>&#187; (void), &#171;<strong>I<\/strong>&#187; (jint) \u0438\u043b\u0438 &#171;<strong>[IIIIIII<\/strong>&#187; (\u043c\u0430\u0441\u0441\u0438\u0432 jint, \u0438 6 jint \u0437\u0430 \u043d\u0438\u043c);<\/p>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0445 \u0442\u0438\u043f\u043e\u0432:<code>    <\/code><\/p>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"244\" width=\"244\">\n<p align=\"center\">C\/C++<\/p>\n<\/th>\n<th>\n<p align=\"center\">JNI<\/p>\n<\/th>\n<th data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">Java<\/p>\n<\/th>\n<th data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Signature<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>uint8_t\/unsigned char<\/p>\n<\/td>\n<td>\n<p align=\"center\">jboolean<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">bool<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Z<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int8_t\/char\/signed char<\/p>\n<\/td>\n<td>\n<p align=\"center\">jbyte<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">byte<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">B<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>uint16_t\/unsigned short<\/p>\n<\/td>\n<td>\n<p align=\"center\">jchar<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">char<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">C<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int16_t\/short<\/p>\n<\/td>\n<td>\n<p align=\"center\">jshort<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">short<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">S<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int32_t\/int\/(long)<\/p>\n<\/td>\n<td>\n<p align=\"center\">jint<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">int<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">I<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>int64_t\/(long)\/long long<\/p>\n<\/td>\n<td>\n<p align=\"center\">jlong<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">long<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">J<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>float<\/p>\n<\/td>\n<td>\n<p align=\"center\">jfloat<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">float<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">F<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>double<\/p>\n<\/td>\n<td>\n<p align=\"center\">jdouble<\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">double<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">D<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"244\" width=\"244\">\n<p>void<\/p>\n<\/td>\n<td>\n<p>                  <\/p>\n<\/td>\n<td data-colwidth=\"128\" width=\"128\">\n<p align=\"center\">void<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">V<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b \u043c\u0430\u0441\u0441\u0438\u0432\u043e\u0432:<code>    <\/code><\/p>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"216\" width=\"216\">\n<p align=\"center\">JNI<\/p>\n<\/th>\n<th data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">Java<\/p>\n<\/th>\n<th>\n<p align=\"center\">Signature<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jbooleanArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">bool[]<\/p>\n<\/td>\n<td>\n<p>[Z<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jbyteArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">byte[]<\/p>\n<\/td>\n<td>\n<p>[B<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jcharArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">char[]<\/p>\n<\/td>\n<td>\n<p>[C<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jshortArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">short[]<\/p>\n<\/td>\n<td>\n<p>[S<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jintArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">int[]<\/p>\n<\/td>\n<td>\n<p>[I<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jlongArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">long[]<\/p>\n<\/td>\n<td>\n<p>[L<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jfloatArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">float[]<\/p>\n<\/td>\n<td>\n<p>[F<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jdoubleArray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">double[]<\/p>\n<\/td>\n<td>\n<p>[D<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jarray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">type[]<\/p>\n<\/td>\n<td>\n<p>[Lfully\/qualified\/type\/name;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"216\" width=\"216\">\n<p>jarray<\/p>\n<\/td>\n<td data-colwidth=\"176\" width=\"176\">\n<p align=\"center\">String[]<\/p>\n<\/td>\n<td>\n<p>[Ljava\/lang\/String;<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>\u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c \u043c\u0430\u0441\u0441\u0438\u0432\u0430, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c JNI-\u043c\u0435\u0442\u043e\u0434\u044b \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/doc.qt.io\/qt-5\/qandroidjnienvironment.html\" rel=\"noopener noreferrer nofollow\">QAndroidJniEnvironment<\/a>, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a: NewIntArray, GetIntArrayElements, DeleteLocalRef GetArrayLength,GetObjectArrayElement, SetObjectArrayElement, \u0438 \u0442.\u0434.<\/p>\n<\/li>\n<\/ol>\n<p>\u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0432 \u043f\u0440\u0435\u0437\u0435\u043d\u0442\u0430\u0446\u0438\u0438 (pdf) <a href=\"https:\/\/www.google.com\/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=&amp;cad=rja&amp;uact=8&amp;ved=2ahUKEwjTqrvL0_3uAhXukosKHfHTAQIQFjABegQIAhAD&amp;url=https%3A%2F%2Fconf.qtcon.org%2Fsystem%2Fattachments%2F132%2Foriginal%2FQtCon16.pdf%253F1473147092&amp;usg=AOvVaw29H2FMnsBW5AMFGk0lNwot\" rel=\"noopener noreferrer nofollow\">Practical Qt on Android JNI \u2014 qtcon<\/a>.<\/p>\n<p>\u0412 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 class <strong>CamShot <\/strong>\u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442:<\/p>\n<ol>\n<li>\n<p>\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f     \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442, \u0432\u0437\u044f\u0442\u044b\u0445 \u0438\u0445 <a href=\"https:\/\/developer.android.com\/training\/camera\/photobasics\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438     \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u043a\u0430 Android<\/a> (\u0442\u0430\u043a     \u043a\u043e\u0434 \u043a\u043e\u0440\u043e\u0447\u0435 \u0438 \u043c\u0435\u043d\u044c\u0448\u0435 Java-\u0432\u044b\u0437\u043e\u0432\u043e\u0432);<\/p>\n<\/li>\n<li>\n<p>\u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u043e\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430 <code>void handleActivityResult(int  receiverRequestCode, int resultCode, const QAndroidJniObject &amp;data) override;<\/code> \u0432  \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f Java-\u043e\u0431\u044a\u0435\u043a\u0442     \u043a\u043b\u0430\u0441\u0441\u0430     <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>     \u0441     \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u043e\u0439 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f;<\/p>\n<\/li>\n<li>\n<p>\u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043c\u0435\u0442\u043e\u0434<br \/><code>static QImage camThumbnailToQImage(const QAndroidJniObject &amp;data);<\/code><br \/>\u0438\u0437\u0432\u043b\u0435\u043a\u0430\u044e\u0449\u0438\u0439 \u0438\u0437 Java-\u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043a\u043b\u0430\u0441\u0441\u0430 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>     Java-\u043e\u0431\u044a\u0435\u043a\u0442 \u043a\u043b\u0430\u0441\u0441\u0430     <a href=\"https:\/\/developer.android.com\/reference\/android\/graphics\/Bitmap\" rel=\"noopener noreferrer nofollow\">Bitmap<\/a>,     \u043a\u043e\u043f\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043f\u0438\u043a\u0441\u0435\u043b\u0438 \u0432 \u043c\u0430\u0441\u0441\u0438\u0432 \u043f\u043a\u0441\u0435\u043b\u0435\u0439     (32-\u0431\u0438\u0442\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439) \u0438 \u043f\u043e\u0441\u0442\u0440\u043e\u0447\u043d\u043e \u043a\u043e\u043f\u0438\u0440\u0443\u044e\u0449\u0438\u0439     \u044d\u0442\u0438 \u043f\u0438\u043a\u0441\u0435\u043b\u0438 \u0432 <a href=\"https:\/\/doc.qt.io\/qt-5\/qimage.html\" rel=\"noopener noreferrer nofollow\">QImage<\/a>;<\/p>\n<\/li>\n<li>\n<p>\u043e\u0431\u0449\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0439 \u0441\u043b\u043e\u0442<br \/><code>void aMakeShot();<\/code><br \/>\u0432\u044b\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u044e \u043f\u043e \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e     \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044e \u0435\u0433\u043e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u044b;<\/p>\n<\/li>\n<li>\n<p>\u0441\u0438\u0433\u043d\u0430\u043b<br \/><code>void createNew(const QImage &amp;img);<\/code><br \/>\u0432\u044b\u0441\u044b\u043b\u0430\u044e\u0449\u0438\u0439 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u0443\u044e \u043c\u0438\u043d\u0438\u0430\u0442\u044e\u0440\u0443 \u043f\u043e\u0442\u0440\u0435\u0431\u0438\u0442\u0435\u043b\u044e.<\/p>\n<\/li>\n<\/ol>\n<p>\u0412 \u043c\u0435\u0442\u043e\u0434\u0435 void <strong>aMakeShot<\/strong>() \u0441\u043e\u0437\u0434\u0430\u0451\u0442\u0441\u044f Java-\u043e\u0431\u044a\u0435\u043a\u0442 <a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a> \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u0441\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c, \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u043c, \u0447\u0442\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u2014 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0441\u0442\u0438 \u0437\u0430\u0445\u0432\u0430\u0442 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f. \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0441\u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 (<a href=\"https:\/\/developer.android.com\/reference\/android\/content\/Intent?hl=en\" rel=\"noopener noreferrer nofollow\">Intent<\/a>) \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430 \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 (<a href=\"https:\/\/developer.android.com\/reference\/android\/app\/Activity\" rel=\"noopener noreferrer nofollow\">Activity<\/a>).<\/p>\n<p>\u0412 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e-\u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0434\u043b\u044f \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u041a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u044f \u0431\u0443\u0434\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u043d\u0430 \u0438 \u043f\u043e\u0434\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c, \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0434\u0451\u043d \u0432\u044b\u0437\u043e\u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430 <strong><em>handleActivityResult<\/em><\/strong>, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430: \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435<\/p>\n<\/li>\n<\/li>\n<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-318767","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/318767","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=318767"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/318767\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=318767"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=318767"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=318767"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}