Merge branch 'master' into fix-third-party-use-of-camera-error

pull/324/head
Okafor Ezewuzie 7 years ago committed by GitHub
commit c7cb7fdd53
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 34
      .github/ISSUE_TEMPLATE/bug_report.md
  2. 17
      .github/ISSUE_TEMPLATE/feature_request.md
  3. 12
      .github/ISSUE_TEMPLATE/question.md
  4. 10
      .github/pull_request_template.md
  5. 26
      .github/stale.yml
  6. 28
      ISSUE_TEMPLATE.md
  7. 2
      README.md
  8. 7
      cameraview/src/main/java/com/otaliastudios/cameraview/Camera1.java

@ -0,0 +1,34 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''
---
### Describe the bug
A clear and concise description of what the bug is.
- CameraView version: *version number*
- Reproducible in official demo app: *yes/no*
- Device / Android version: *Pixel, API 28*
### To Reproduce
Steps to reproduce the behavior, possibly in the demo app:
1. Go to '...'
2. Click on '....'
3. See error
### Expected behavior
A clear and concise description of what you expected to happen.
### Screenshots
If applicable, add screenshots to help explain your problem.
### Logs
Use `CameraLogger.setLogLevel(LEVEL_VERBOSE)` to see all logs into LogCat.
Use `CameraLogger.registerLogger()` to export to file or crash reporting service.
### APK
Link to a Github repo where the bug is reproducible.

@ -0,0 +1,17 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''
---
### Problem to be addressed
A clear and concise description of what the problem is.
### Describe the solution you'd like
A clear and concise description of what you want to happen.
### Additional context
Add any other context or screenshots about the feature request here.

@ -0,0 +1,12 @@
---
name: Question
about: Question about CameraView usage
title: ''
labels: is:question
assignees: ''
---
### How do I?
Describe your problem here. Please, read the docs first.
Questions not strictly related to CameraView should be asked elsewhere.

@ -0,0 +1,10 @@
### Before you go
Unless this is a simple fix (typos, bugs with obvious solution), please open an issue first.
If the edited files were covered by tests, updated tests are required for merging. Please look into the tests folders and make sure you cover new code.
- Fixes ... (*issue number*)
- Tests: ... (*yes/no*)
- Docs updated: ... (*yes/no*)
### Solution
If applicable, briefly describe how the issue was addressed.

@ -0,0 +1,26 @@
# Configuration for probot-stale - https://github.com/probot/stale
# Number of days of inactivity before an Issue or Pull Request becomes stale
daysUntilStale: 20
# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
daysUntilClose: 7
# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable
exemptLabels:
- is:bug
- is:enhancement
- is:discussion
# Label to use when marking as stale
staleLabel: status:stale
# Comment to post when marking as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
activity in the last 20 days. It will be closed if no further activity
occurs within the next seven days. Thank you for your contributions.
# Limit to only `issues` or `pulls`
only: issues

@ -1,28 +0,0 @@
*If you are trying to report a bug, please file the information below.
Prerequisites:*
<!-- Add [x] inside the brackets -->
- [ ] *I am using the latest version*
- [ ] *I can reproduce the bug in the demo app, and if not...*
- [ ] *I have tried to reproduce the bug in the demo app*
#### Detailed steps to reproduce the issue:
1.
2.
3.
#### Expected behavior:
#### Actual behavior:
#### Screenshots:
#### Interesting logs:
*You can use `CameraLogger.setLogLevel(LEVEL_VERBOSE)`
to add logs to logcat, and `CameraLogger.registerLogger()`
to handle logs yourself (e.g. export to file or a crash reporting service)
so you can collect data from your users.*

@ -411,7 +411,7 @@ Most camera parameters can be controlled through XML attributes or linked method
app:cameraSessionType="picture"
app:cameraCropOutput="false"
app:cameraJpegQuality="100"
app:cameraVideoQuality="480p"
app:cameraVideoQuality="max480p"
app:cameraVideoCodec="deviceDefault"
app:cameraWhiteBalance="auto"
app:cameraHdr="off"

@ -823,6 +823,7 @@ class Camera1 extends CameraController implements Camera.PreviewCallback, Camera
mCamera.setParameters(params);
mCameraCallbacks.dispatchOnFocusStart(gesture, p);
// TODO this is not guaranteed to be called... Fix.
try {
mCamera.autoFocus(new Camera.AutoFocusCallback() {
@Override
public void onAutoFocus(boolean success, Camera camera) {
@ -832,6 +833,12 @@ class Camera1 extends CameraController implements Camera.PreviewCallback, Camera
mHandler.get().postDelayed(mPostFocusResetRunnable, mPostFocusResetDelay);
}
});
} catch (RuntimeException e) {
// Handling random auto-focus exception on some devices
// See https://github.com/natario1/CameraView/issues/181
LOG.e("startAutoFocus:", "Error calling autoFocus", e);
mCameraCallbacks.dispatchOnFocusEnd(gesture, false, p);
}
}
});
}

Loading…
Cancel
Save