Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ios/ReactNativeCameraKit/CKCamera.m
Original file line number Diff line number Diff line change
Expand Up @@ -597,7 +597,7 @@ - (void)capturePreviewLayer:(NSDictionary*)options success:(CaptureBlock)onSucce
if (self.mockPreview != nil) {
UIImage *previewSnapshot = [self.mockPreview snapshotWithTimestamp:YES]; // Generate snapshot from main UI thread
dispatch_async( self.sessionQueue, ^{ // write image async
[self writeCapturedImageData:UIImagePNGRepresentation(previewSnapshot) onSuccess:onSuccess onError:onError];
[self writeCapturedImageData:UIImageJPEGRepresentation(previewSnapshot, 0.85) onSuccess:onSuccess onError:onError];
});
} else {
onError(@"Simulator image could not be captured from preview layer");
Expand Down