ekreutz / react-native-barcode-scanner-google

Barcode scanner for react native, which implements barcode detection from Google's Vision API.
MIT License
113 stars 68 forks source link

IOS estension #13

Open sbobykin opened 6 years ago

sbobykin commented 6 years ago

Hello. I'm writing an IOS extension: https://github.com/sbobykin/react-native-barcode-scanner-google/blob/ios/IOS.md .

Here I'd like to start discussion about the extension.

That would be great if someone tries to run and test it.

ducpt2 commented 6 years ago

@sbobykin i run barcode example in https://github.com/googlesamples/ios-vision, and it work. i follow your guild in https://github.com/sbobykin/react-native-barcode-scanner-google/blob/ios/IOS.md but i can run, linked error.

Can you provide an example work in react native? It's very helpful Thank you.

sbobykin commented 6 years ago

Hello @ducpt2! Thanks for your trial.

Could you provide your error message?

ducpt2 commented 6 years ago

@sbobykin here my error: ld: library not found for -lswiftSwiftOnoneSupport for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)

i follow your link to setup. Pls help me and make it work on ios (React Native). Thanks

ducpt2 commented 6 years ago

@sbobykin Are you working on it? I can test it for you if you are finish 😀 Thanks.

sbobykin commented 6 years ago

@ducpt2 thanks!) Currently I can't reproduce your error message. At the end of this week I'll put a sample to try without passing all the steps in the ios instruction.

ducpt2 commented 6 years ago

@sbobykin seem like pretty nice. Thank you for your effort.

ducpt2 commented 6 years ago

Currently i am trying my own bridge, but i realize when i using pod install, all lib download down is different when compare with native ios-vision example: +react-native pod install: -GoogleMobileVision, GoogleToolboxForMac, GTMSessionFetcher, Protobuf. +ios-vision example pod install: -GoogleInterchangeUtilities, GoogleMobileVision, GoogleNetworkingUtilities, GoogleSymbolUtilities, GoogleUtilities. Why it so different when i using the same pod file to run? Can you explain please, i guess this is why i has error like above :)) Thanks.

sbobykin commented 6 years ago

On my side (react native case) I have GoogleInterchangeUtilities, GoogleMobileVision, GoogleNetworkingUtilities, GoogleSymbolUtilities, GoogleUtilities. That's the same like in your ios-vision case.

I think that would be great to have a voice talk with screen sharing. If you agree please write me to email that you can find in my commits.

sbobykin commented 6 years ago

@ducpt2 try please https://github.com/sbobykin/react-native-barcode-scanner-google/blob/ios/helpersios/sample_ios/README.md

ducpt2 commented 6 years ago

@sbobykin i am sorry, i follow your step but it can't work, i think the issue is my pod install wrong file, maybe if you can update all project (include pod file, pod project) i can run. I am trying to figure out why it happen :) btw, thank you and please let me know if you know how to fix my issue :)

ducpt2 commented 6 years ago

@sbobykin i created ios native (Swift) with GMV barcode detect, and it work. now I am trying to make react native working too :)

ekreutz commented 6 years ago

This is very cool! Is it also based on work by Google, or is it some other integration??

ducpt2 commented 6 years ago

@ekreutz And i can't let it work with RN =))) too bad. always show error when i am trying to run (using pod to install GMV). Need someone expert iOS to fix the problem in there. @ekreutz using GMV of google.

sbobykin commented 6 years ago

@ducpt2 @ekreutz sorry for my late reaction to your comments.

@ekreutz yes that's based on GMV. I want to change architecture of the current ios bridge (to make it cleaner and better) then I would like to do pull request.

@ducpt2 after architecture recreation. There won't be any ViewController stuff. That would be great to try on your side. Do you have successful compiling right now? If no, could you provide error message?

daominhsangvn commented 6 years ago

@sbobykin Thanks so much for your hard work on iOS implementation, i was successfully run your sample code and the scanning very fast. Great Job!

kirill578 commented 6 years ago

Am I the only one who gets 'GoogleMobileVision.h' file not found when compiling the xcode project?

daominhsangvn commented 6 years ago

@kirill578 try to re-locate those files

image

kapil708 commented 5 years ago

hi @daominhsangvn with which path to change the old one.

kapil708 commented 5 years ago

hi @daominhsangvn with which path to change the old one.

I solved it but got new error. linker command failed with exit code 1 (use -v to see invocation)