Michaelvilleneuve / react-native-perspective-image-cropper

Perform custom crop, resizing and perspective correction 📐🖼
MIT License
305 stars 128 forks source link

error: cannot find symbol import org.opencv.RNCustomCropPackage; #25

Closed zahidahmed024 closed 5 years ago

zahidahmed024 commented 5 years ago

"dependencies": { "react": "16.8.3", "react-native": "0.59.5", "react-native-perspective-image-cropper": "^0.4.3", "react-native-svg": "^9.5.1" },

hoboxdomotica commented 5 years ago

same here please help

Michaelvilleneuve commented 5 years ago

Hi, did you properly linked the additional open cv dependency as explained in the readme ? Do you know which line exactly causes the error ?

zahidahmed024 commented 5 years ago

i added "import fr.michaelvilleneuve.customcrop.RNCustomCropPackage; " and removed "import org.opencv.RNCustomCropPackage" in myapplication.java and the error is gone ,

:'(

now im getting only on point -- above the image -- , and when i press crop , i get this error

could not invoke CustomCropManager.crop null native module not found -_-

would u please attach a example project .it will be helpful for us :'( :'(

Michaelvilleneuve commented 5 years ago

I will try to provide an example project. The error means that the native module has not been linked properly

zahidahmed024 commented 5 years ago

hey i did it ,, i installed opencv manually .. thank u so much :D :D ,

Michaelvilleneuve commented 5 years ago

Well done ! What differs from the provided documentation ? Should we update it ?

ZohaibAhmad786 commented 4 years ago

import org.opencv.RNCustomCropPackage; ^ symbol: class RNCustomCropPackage location: package org.opencv D:\Copy Freelance Projects\PerspectiveCorpper\android\app\build\generated\rncli\src\main\java\com\facebook\react\PackageList.java:18: error: cannot find symbol import org.opencv.RNCustomCropPackage; ^ symbol: class RNCustomCropPackage location: package org.opencv

still facing the same issue

ZohaibAhmad786 commented 4 years ago

help me out this problem.

ambessh commented 4 years ago

put this in MainApplication.java import fr.michaelvilleneuve.customcrop.RNCustomCropPackage;

and make a new file in node modules react native perspective image cropper folder named "react-native.config.js" and paste the following code within it.

module.exports = { dependency: {
platforms: {
android: {
packageImportPath: 'import fr.michaelvilleneuve.customcrop.RNCustomCropPackage;',
packageInstance: 'new RNCustomCropPackage()',
},
},
},
};