Commit Graph

355 Commits

Author SHA1 Message Date
rt2zz 7224acd7db Revert "Revert "[iOS]: fix for breaking iOS header change in RN 0.40.0 (#544)""
This reverts commit 47b7cf2ac1.
2017-01-22 19:34:09 -08:00
Philip Nuzhnyi 6421067076 set camera pointer to nil when stopping session in emulator (#523) 2017-01-22 19:33:56 -08:00
Rob Stemen 12afd8443a Fixed issue where Android camera would crash the application if the user attempted to capture too many pictures in a short timeframe. (#553) 2017-01-22 19:33:17 -08:00
Zack Story d116d52442 Update README.md 2017-01-06 12:06:02 -08:00
rt2zz 47b7cf2ac1 Revert "[iOS]: fix for breaking iOS header change in RN 0.40.0 (#544)"
This reverts commit 048e7414d6.
2017-01-06 11:52:27 -08:00
Stefan Dobrev f035e32b30 Handle string values for captureTarget prop (#543)
This change adds a conversion for string values of captureTarget property.
2017-01-05 23:44:45 -08:00
Zack Story 4b089ced6b Update README.md 2017-01-05 23:44:07 -08:00
Paul Ferrett 4babe6573c Fix typo in README.md (#546) 2017-01-05 23:22:18 -08:00
Daniel Kim 048e7414d6 [iOS]: fix for breaking iOS header change in RN 0.40.0 (#544) 2017-01-05 16:07:49 -08:00
rt2zz 330bb18ecb 0.4.1 2017-01-05 12:26:25 -08:00
Nathan Ward f301331b15 [Android): fixes crashes related to orientation (#537) 2017-01-02 13:27:07 -08:00
Gregorio Setti bd40d8a4cf Fix #506 (#525) 2016-12-21 08:35:44 -08:00
Nicolas Charpentier 76963a0a5e Revert "Add video/audio authorization check for Android" (#516) 2016-12-14 17:18:15 -05:00
Üstün Ergenoglu 877ce2e6b2 Add video/audio authorization check for Android (#513)
* Add video/audio authorization check for Android

This only checks for the permission and no request is made. `PermissionAndroid` in recent React Native or manually asking it from native code can still be used.

* Add checkDeviceAuthorizationStatus
2016-12-14 09:52:25 -08:00
pkwak-sf f696610115 Fix issue with updating props quickly causing released camera object to be accessed. (#507) 2016-12-10 08:15:52 -05:00
sunnylqm 536d39b33b barcode now supports android (#508) 2016-12-09 12:18:28 -05:00
Ron Heft b308d08e9a Race conditions initializing flashMode (#436)
* Fix race condition initializing Android camera

* Fix race condition initializing flashMode iOS
2016-12-08 21:05:35 -05:00
Benjamin Toueg 33bd0c4737 Android pinch to zoom (#498)
* Android pinch-to-zoom feature.

* Missing import.
2016-12-05 19:58:17 -05:00
Alexander Pantyuhov 06dc7ac5a7 Image orientation fix (#475, #309) (#493)
fix
2016-12-04 18:32:04 -05:00
Ron Heft fd61e506e5 Document other iOS authorization status methods (#427)
The API already exposes specific methods for checking camera and microphone access individually. These should be documented. Especially since calling `checkDeviceAuthorizationStatus` requests the microphone permission, which is undesirable in photo-only use cases.
2016-11-30 20:25:23 -05:00
Anton Shevchenko 9e06741e94 Include microphone permission key in Info.plist (#488)
* Include microphone permission key in Info.plist

Mention microphone permission (and what to add to `Info.plist) for iOS 10 and up.

* Update README.md
2016-11-28 20:15:42 -05:00
Benjamin Toueg 3a20709f64 Minor: Remove duplicate if (#487) 2016-11-26 13:07:07 -05:00
Loch Wansbrough 69d6b5acbf Update README.md 2016-11-23 12:59:36 -08:00
Locly 154cb7aa58 Added Camera.constants.CaptureQuality.preview for android to allow the outputted image to be exactly the same as the previewed image (#449) 2016-11-21 19:41:19 -05:00
Zack Story e4536fd896 Update README.md 2016-11-20 15:12:45 -08:00
rt2zz a8c07ff4fd 0.4.0 2016-11-20 15:10:17 -08:00
Ian Bussières 3f04dd3587 Fix crash on second invocation of camera when running on iOS 10 simulator (#441) 2016-11-18 17:45:21 -05:00
James 6fe07c48ae Explicitly added instructions for the Camera Usage Description for iO… (#478)
* Explicitly added instructions for the Camera Usage Description for iOS 10

* Added NSPhotLib field as well
2016-11-18 17:42:03 -05:00
abrahambotros a2a6d028a4 Add 1080p, 720p, and 480p capture qualities. (#469)
* Add 1080p, 720p, and 480p capture qualities.

* Minor improvements for picture/video sizing.

- Minor refactoring for getting supported sizes (DRY).
- Add explicit pictureSize setting for 480p/720p/1080p in still/picture mode.

* Use util.Size objects for 480p/720p/1080p sizing.

- Note using Camera.Size objects would require a camera instance prior to creating the
  size objects, which would be manageable but not too clean.

* Remove 480p for iOS; 16:9/HD aspect ratio for Android 480p

- iOS only has a 640x480 480p-like AVCaptureSessionPreset, which is not the typical 16:9/HD aspect ratio
  desired. Removing this option as a result of this.
- Android 480p updated to use 16:9/HD aspect ratio.

* Add notes for (in)exact sizing for 1080p/720p/480p

* Re-add 480p on iOS, more notes on resolutions.

- Add notes on non-HD-aspect-ratio for iOS 480p.
- Add more explanation of variable resolution/sizes, especially for 480p on Android.

* Use custom Resolution class to hold 480p/720p/1080p resolution sizes

- Mistakenly used util.Size class before, which was not added until Android API level 21 (current
  min is 16).
2016-11-18 17:38:23 -05:00
Jonathan Chen adb26f4524 Default captureAudio to false (#420)
* Default captureAudio to false

Since default captureMode is a still picture, not video. 

This also works around some new iOS 10 permissions requiring notifying the user with a reason for using microphone (which is not good for the user experience if they're just taking a picture). Reference: https://github.com/lwansbrough/react-native-camera/issues/386#issuecomment-249007206

If you need video and sound, then explicitly pass it through as props in your Camera component.

* Update readme for default audio setting
2016-11-18 17:35:26 -05:00
Nicolas Charpentier 4badcd2596 Merge pull request #480 from lwansbrough/update-example
Update example
2016-11-18 16:31:37 -05:00
rt2zz 26070b58d0 remove gitignore 2016-11-17 22:29:08 -08:00
abrahambotros b16ec4ab75 Minor Android MediaRecorder, sizing, and file improvements (#477)
Android MediaRecorder:
  - Most importantly, call Camera.unlock() before setting the camera on the
    MediaRecorder instance, and release() not just reset() when releasing the MediaRecorder
    instance!
  - Add comments and notes for preparing and releasing MediaRecorder instance.
  - Add onError callback for errors during recording session.

RCTCameraViewManager, RCTCamera, RCTCameraViewFinder, RCTCameraView:
  - Implement setCaptureMode, preparing camera based on captureMode. Currently, the only step that
    needs to be taken here is setting the recording hint for videos.
  - Handle setting _captureMode instance variable where applicable.

Sizing
  - Determine ViewFinder supported sizes based on actual captureMode (i.e., get supported picture
    sizes when in still capture mode, and get supported video sizes when in video capture mode).

Output files:
  - Get appropriate external storage public directory based on media type (image or video).
  - Minor variable renaming to indicate that both images or videos can be saved.

README:
  - Update captureTarget to indicate that cameraRoll is the actual default for both systems.
  - Small clarification for output data type for deprecated memory captureTarget output.
2016-11-17 22:25:51 -08:00
Livio Bieri fb3b12b4f1 README: Updated Requirements for iOS 10 (#445) 2016-10-12 20:35:13 -04:00
Andrew Jack a51041e41a Fix .gitignore and add .npmignore (#455) 2016-10-12 20:34:40 -04:00
Zack Story 6074ec3c82 Merge pull request #423 from node-vision/master
Fix for issue #386 - camera cras- ios 10 simulator
2016-09-26 07:50:04 +02:00
Roman Mandryk 000c09a2cc Fix for issue #386 - camera cras- ios 10 simulator 2016-09-24 21:18:41 +08:00
Nicolas Charpentier 880f469082 Update Example to RN 0.34 and Xcode 8 2016-09-23 16:08:56 -04:00
Zack Story 1747ec4b0a Merge pull request #413 from plougsgaard/android-barcode-scanner-rebased
Android Barcode Scanner
2016-09-16 22:50:52 -07:00
plougsgaard 05b5fc727d Support hints for a subset of the barcode types. 2016-09-15 21:30:00 +02:00
plougsgaard 918c00f003 Apply barcode scanner on preview frames. 2016-09-15 01:17:24 +02:00
plougsgaard ce11617743 Add event emitter for android. 2016-09-15 01:16:20 +02:00
plougsgaard 85336e9fd4 Import the zxing decoder library. 2016-09-15 01:16:20 +02:00
plougsgaard 2a33908c4f Expose the react application context as a singleton. 2016-09-15 01:16:19 +02:00
plougsgaard b5af30248e Add internal prop determining if barcode scanner is wanted. 2016-09-15 01:16:19 +02:00
Chris Duke d15022d560 Fix bug 357. Setting preview callback to null before camera release. (#410) 2016-09-13 14:17:45 -07:00
Gonzalo Aguirre 22f79985b2 Add missing dependency (#411)
* Add mirrorImage support for Android

* Release resources after mirroring

* Mirror image only for TYPE_FRONT

* Remove unnecessary annotation

* Document mirrorImage for Android

* Improved compression and error handling

* Add support for mirroring on Android back camera too
2016-09-13 14:16:27 -07:00
Gonzalo Aguirre b01c64e773 Mirror image for Android (#399)
* Add mirrorImage support for Android

* Release resources after mirroring

* Mirror image only for TYPE_FRONT

* Remove unnecessary annotation

* Document mirrorImage for Android

* Improved compression and error handling

* Add support for mirroring on Android back camera too
2016-09-13 09:48:48 -07:00
jacobSingh 2bbdf8ce91 Update README.md (#407) 2016-09-13 02:08:25 -07:00
David 3ff9a5852a Update Readme (#406)
for everyone that links it manually  - see: https://github.com/lwansbrough/react-native-camera/issues/164
2016-09-13 01:21:28 -07:00