YouTube watchme Android应用程序异常找不到“libffmpeg.so”

时间:2017-05-24 05:26:06

标签: android android-youtube-api youtube-data-api youtube-livestreaming-api android-ffmpeg

我正在使用此示例https://github.com/youtube/yt-watchme

我刚刚导入了示例并在MainActivity中设置了ACCOUNT_KEY。 下面是Build gradle文件

apply plugin:'com.android.application'

java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.google.android.apps.watchme-1/base.apk"],nativeLibraryDirectories=[/data/app/com.google.android.apps.watchme-1/lib/arm64, /vendor/lib64, /system/lib64]]] couldn't find "libffmpeg.so"
                                                                                         at java.lang.Runtime.loadLibrary(Runtime.java:367)
                                                                                         at java.lang.System.loadLibrary(System.java:1076)
                                                                                         at com.google.android.apps.watchme.Ffmpeg.<clinit>(Ffmpeg.java:26)
                                                                                         at com.google.android.apps.watchme.VideoStreamingConnection.open(VideoStreamingConnection.java:71)
                                                                                         at com.google.android.apps.watchme.StreamerService.startStreaming(StreamerService.java:72)
                                                                                         at com.google.android.apps.watchme.StreamerActivity.startStreaming(StreamerActivity.java:208)
                                                                                         at com.google.android.apps.watchme.StreamerActivity.access$200(StreamerActivity.java:46)
                                                                                         at com.google.android.apps.watchme.StreamerActivity$1.onServiceConnected(StreamerActivity.java:66)
                                                                                         at android.app.LoadedApk$ServiceDispatcher.doConnected(LoadedApk.java:1274)
                                                                                         at android.app.LoadedApk$ServiceDispatcher$RunConnection.run(LoadedApk.java:1291)
                                                                                         at android.os.Handler.handleCallback(Handler.java:815)
                                                                                         at android.os.Handler.dispatchMessage(Handler.java:104)
                                                                                         at android.os.Looper.loop(Looper.java:207)
                                                                                         at android.app.ActivityThread.main(ActivityThread.java:5776)
                                                                                         at java.lang.reflect.Method.invoke(Native Method)
                                                                                         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:789)
                                                                                         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:679)

This is my project structure

在我的手机上运行此应用程序时,我收到以下异常

com.google.api.client.googleapis.json.GoogleJsonResponseException: 403 Forbidden
                                                                      {
                                                                        "code": 403,
                                                                        "errors": [
                                                                          {
                                                                            "domain": "youtube.liveBroadcast",
                                                                            "message": "Stream is inactive",
                                                                            "reason": "errorStreamInactive",
                                                                            "extendedHelp": "https://developers.google.com/youtube/v3/live/docs/liveBroadcasts/transition"
                                                                          }
                                                                        ],
                                                                        "message": "Stream is inactive"
                                                                      }
                                                                          at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:113)
                                                                          at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:40)
                                                                          at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:321)
                                                                          at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1065)
                                                                          at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419)
                                                                          at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)
                                                                          at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)
                                                                          at com.google.android.apps.watchme.util.YouTubeApi.startEvent(YouTubeApi.java:187)
                                                                          at com.google.android.apps.watchme.MainActivity$StartEventTask.doInBackground(MainActivity.java:408)
                                                                          at com.google.android.apps.watchme.MainActivity$StartEventTask.doInBackground(MainActivity.java:393)
                                                                          at android.os.AsyncTask$2.call(AsyncTask.java:292)
                                                                          at java.util.concurrent.FutureTask.run(FutureTask.java:237)
                                                                          at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
                                                                          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
                                                                          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
                                                                          at java.lang.Thread.run(Thread.java:818)

上述错误已修复并收到此新错误

datepicker

请帮我解决这个问题...

1 个答案:

答案 0 :(得分:1)

https://developers.google.com/youtube/v3/live/docs/liveBroadcasts/transition

使用此链接。您将了解为什么会出现此错误。还有一些其他错误及其详细原因。