gsssrao / UnityAndroidSpeechRecognition

This repository is a Unity plugin for Android Speech Recognition (based on Java implementation)
GNU General Public License v3.0
87 stars 29 forks source link

Unable to include code into Unity Project #1

Closed RigosaaCL closed 6 years ago

RigosaaCL commented 6 years ago

Hi, first off, thanks form making this public.

I have what it must be a very simple problem, my Unity project doesn't work after importing SpeechRecognition.unitypackage, using Unity 5.3.3f1, on Win 7 64bits, and running the apk in a Samsug Galaxy S5 running Android 5.0. The first thing to mention is that your apk works wondeful on it own, but:

  1. If I run my apk (your unitypackage imported into my project), it crashes, shows the default Unity splash for just 1 sec, besides is strange that the splash looks not centered and that the app icon is lost and replaced by the default Android icon.
  2. If I delete AndroidManifest.xml file from the project and compile again, the apk loads successfully, so I'm able to click the "speak button", then the google api window shows up, I'm able to speak, my speech is "recognized" as the google api window closes, BUT... no words are shown on 'TextRecognition' UI Text component, seems that by deleting the xml file, I broke the possibility that the callback method onActivityResult() gets called. Though at least my app doesn't crash and my app icon is back again!

I'm a good C# programmer and been using Unity for more than two years, but dealing with Android api classes and xml manifest files is beyond my knowledge, so far now.

Any help would be apprecciated.

Regards, Rodrigo

gsssrao commented 6 years ago

Hey @RigosaaCL, sorry for the really late reply. My bad, I forgot to follow up.

I have updated the repository recently and hopefully this should solve all the problems. Let me know if you are still facing any problems.