Merge pull request #423 from node-vision/master
Fix for issue #386 - camera cras- ios 10 simulator
This commit is contained in:
commit
6074ec3c82
|
@ -30,10 +30,11 @@ RCT_EXPORT_MODULE();
|
|||
- (UIView *)view
|
||||
{
|
||||
self.session = [AVCaptureSession new];
|
||||
|
||||
self.previewLayer = [AVCaptureVideoPreviewLayer layerWithSession:self.session];
|
||||
self.previewLayer.needsDisplayOnBoundsChange = YES;
|
||||
|
||||
#if !(TARGET_IPHONE_SIMULATOR)
|
||||
self.previewLayer = [AVCaptureVideoPreviewLayer layerWithSession:self.session];
|
||||
self.previewLayer.needsDisplayOnBoundsChange = YES;
|
||||
#endif
|
||||
|
||||
if(!self.camera){
|
||||
self.camera = [[RCTCamera alloc] initWithManager:self bridge:self.bridge];
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue