teslamotors / react-native-camera-kit

A high performance, easy to use, rock solid camera library for React Native apps.
MIT License
2.49k stars 590 forks source link

When I am zooming, it's capturing black and white image #597

Open dhaval97micro1 opened 1 year ago

dhaval97micro1 commented 1 year ago

Describe the bug I am using Camera in my app and have enabled the zooming feature using the default provided prop, when I zoom in and capture the camera, it captures a black-and-white image

To Reproduce Below is my code:

<Camera ref={cameraRef} torchMode={flashMode} style={{ aspectRatio: 3 / 4, }} focusMode="on" resetFocusWhenMotionDetected={true} hideControls={true} // (default false) optional, hides camera controls showCapturedImageCount={false} // (default false) optional, show count for photos taken during that capture session />

// Capture method const onCapture = async () => { let {uri} = await cameraRef.current.capture(true); if (uri.startsWith('file://')) { let path = uri; setImageToCrop(path); } };

Expected behavior It should keep the colours as it is and not make it black and white

Screenshots

Screenshot 2023-10-06 at 1 26 52 PM Screenshot 2023-10-06 at 1 28 09 PM

Additional context Mainly facing this issue with iPhone 14 pro and iOS 17.0.2

scarlac commented 1 year ago

Can you reproduce this with the example project?