sxudan / react-native-video360

This is a react native package to play 360 videos or VR videos.
https://www.npmjs.com/package/react-native-video360
MIT License
0 stars 0 forks source link

Plugin Not Working on Android Device. #2

Open yavuzgunay opened 12 months ago

yavuzgunay commented 12 months ago

Hi @sxudan,

It does not work after installing the plugin on your Android device. What can I do to make it work?

Thanks

Simulator Device : Pixel API 34

Android Studio Error

Could not determine the dependencies of task ':app:processDebugResources'.
> Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
   > Could not find com.google.vr:sdk-videowidget:1.170.0.
     Searched in the following locations:
       - https://oss.sonatype.org/content/repositories/snapshots/com/google/vr/sdk-videowidget/1.170.0/sdk-videowidget-1.170.0.pom
       - https://repo.maven.apache.org/maven2/com/google/vr/sdk-videowidget/1.170.0/sdk-videowidget-1.170.0.pom
       - file:/Volumes/External/Projects/VRReactNativeApp/node_modules/jsc-android/dist/com/google/vr/sdk-videowidget/1.170.0/sdk-videowidget-1.170.0.pom
       - https://dl.google.com/dl/android/maven2/com/google/vr/sdk-videowidget/1.170.0/sdk-videowidget-1.170.0.pom
       - https://www.jitpack.io/com/google/vr/sdk-videowidget/1.170.0/sdk-videowidget-1.170.0.pom
     Required by:
         project :app > project :react-native-video360

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
yavuzgunay commented 12 months ago

Hi @sxudan ,

Today I did research to solve the problem in Android. I couldn't test it because I don't have much Java knowledge. In a project 4 years ago, jar file implementation could be done. Additionally, the Google VR library is disabled. Instead, the Google Cardboard library can be used via Android NDK. The repository is constantly kept up to date.

//Google Cardboard Links https://developers.google.com/cardboard/develop/c/quickstart https://github.com/googlevr/cardboard

//Jar Implement

GoogleVr.jar Resource : https://github.com/ktaeyang/react-native-video360/tree/master/android/libs

// From node_modulesimplementation files('libs/GoogleVr.jar') implementation files('libs/GoogleVr.jar')

GoogleVr.zip