Skip to content

Add CameraActivity utility class to automate Camera permission handling on Android#15105

Merged
opencv-pushbot merged 1 commit intoopencv:masterfrom
komakai:camera_permissions
Jul 22, 2019
Merged

Add CameraActivity utility class to automate Camera permission handling on Android#15105
opencv-pushbot merged 1 commit intoopencv:masterfrom
komakai:camera_permissions

Conversation

@komakai
Copy link
Copy Markdown
Contributor

@komakai komakai commented Jul 20, 2019

resolves #13514

This pullrequest changes

  • Add CameraActivity class to request Camera permission when required
  • Update Android samples to derive from this class instead of Activity
  • Make additional changes to samples that enable/disable menu options based on camera capabilities such that the menu option processing only occurs after the camera permissions have been granted and the camera has started

Tests

Tested on

  • Lollipop (permission request dialog not required)
  • Pie (permission request dialog required)

Copy link
Copy Markdown
Member

@alalek alalek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done! Thank you 👍

@opencv-pushbot opencv-pushbot merged commit 2734291 into opencv:master Jul 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Android: update samples (camera permissions)

3 participants