0

Actually I am trying to get live camera feed from the drone which I want to see on my screen of my smartphone. I have tried to add the library "FFmpeg" to my project, but it's throwing the following errors:

DllImport attempting to load: 'avcodec-55'.
DllImport error loading lbavcodec-55': 'dlopen failed: libavcodec-55" not found'.
DllImport error loading libavcodec-55.so': 'dlopen failed: libavcodec-55.so" not found'.
DllImport error loading libavcodec-55': 'dlopen failed: libavcodec-55" not found'.
DllImport error loading libavcodec-55.so': 'dlopen failed: libavcodec-55.so" not found'.
DllImport error loading library 'libavcodec-55': 'dlopen failed: libavcodec-55" not found'.

There it is saying that he can't find the libraries, but they are for Windows and not for Xamarin Android. So I just want to compile those dlls, but I don't know how this is even possible. Is there someone that has already compiled those dlls?

Thanks!

Jamie
  • 363
  • 7
  • 19
  • You can follow instructions at https://github.com/mconf/android-ffmpeg, but this may not be easy on Windows. The easiest step would be to start with prebuilt ffmpeg library, e.g. https://github.com/roman10/android-ffmpeg-tutorial/tree/master/android-ffmpeg-tutorial01/libs/armeabi – Alex Cohn May 15 '16 at 07:52
  • Hey @AlexCohn, thanks for your reply. Yes I have seen those projects, but I don't really understand it, because I should have .dll files and that are .so files? What's the difference? And how can I import those files into my project Xamarin? – Jamie May 15 '16 at 13:04
  • Android uses .so libraries, even in Xamarin under the hood. See for example http://stackoverflow.com/a/15902529/192373 – Alex Cohn May 15 '16 at 18:58
  • You are right @AlexCohn, so I deleted it. I thought the structure solved my problem because I was working in a .bak file which is not working of course. So I added the ItemGroup on the same way as the link you sent me. But the files can't be found. I set the .so files to "Copy always" but I still don't see the .so files in the folder on my smartphone. So I understand the error. – Jamie May 16 '16 at 11:27
  • First, analyze your package that is being installed on the phone. Are the **libav….so** files packed there? – Alex Cohn May 16 '16 at 12:06
  • @AlexCohn Okay, I get it. I am trying to analyze the package on the smartphone. I don't see any libraries. Do I need to create an .apk file for this? If I go to my properties I see that it's supporting the "armeabi" and "armeabi-v7a" architectures. In the packaging tab it's saying "Use Shared Runtime" and "Use Fast Deployment", that's it. Nothing more. – Jamie May 16 '16 at 14:30
  • Yes, your APK should contain the shared libraries. Probably, the paths that you specify in `<AndroidNativeLibrary` tag are wrong. Maybe, that's because you assume a wrong "root" for these paths. – Alex Cohn May 16 '16 at 18:38
  • @AlexCohn the path to the .so files are fine I guess. They are located in my .csproj file – Jamie May 16 '16 at 18:41

0 Answers0