ivpusic / react-native-image-crop-picker

iOS/Android image picker with support for camera, video, configurable compression, multiple images and cropping
MIT License
6.12k stars 1.56k forks source link

openCropper() is not returning the image with correctly cropped dimensions. #1163

Open ManalLiaquat opened 4 years ago

ManalLiaquat commented 4 years ago

Version

Tell us which versions you are using:

Platform

Tell us to which platform this issue is related

I am using both platforms.

Expected behaviour

It should crop the image in dimension what I pass.

Actual behaviour

I want to crop the image (of any dimension) into dimension 320100 but it is returning the resultant image with different dimensions like: 319100 when I zoom the image in cropper or tilt the image in cropper.

Steps to reproduce

  1. ImagePicker.openCropper({
            path: imagePath,
            320,
            100
        }).then(image => {
            console.log(image);
           }).catch(err=>console.log(err))

Attachments

// stacktrace or any other useful debug info

Love react-native-image-crop-picker? Please consider supporting our collective: 👉 https://opencollective.com/react-native-image-crop-picker/donate

lethienhung commented 4 years ago

I've the same problem

kumari-pallavi-ally commented 4 years ago

react-native ^ 6.9.0 react-native-image-crop-picker^0.26.1 Getting Error: { "framesToPop": 1, "nativeStackAndroid": [], "userInfo": null, "code": "E_NO_IMAGE_DATA_FOUND" } ImagePicker.opencropper function is not giving the .then(image =>{}) result How do I solve this error?

hanaechahid commented 4 years ago

for me ImagePicker.openCamera method is not giving the result on then

b3hz4d commented 3 years ago

I had the same problem and found that when setting state before using ImagePicker.openCropper, It's not showing up on rerender Check if there is any setState before using it

mgallegoavi commented 2 years ago

I have the same problem, the "openCropper" method always returns a lower height than the one I set.