Log in or register to post comments

Vuforia Video Playback on Android with Unity

September 16, 2015 - 12:30am #1

Hello all! 

i work on an Android app and use Unity (5).

My app has a lot off 3D content and the apk is bigger then 50 MB. Now i have split the app in an APK and an Obb File.

The split was a long way, but the app works good. Vuforia AR is still running and i see my 3D content on various markers. 

 

Now i would use the Vuforia Video Playback plugin. When i build the app without splitting, the videos running on every Android device. But when i split the app, and run

it on Android, the video player dont find the video content in the obb file. 

 

 

I unzip the .xml and .dat file from the Obb file and save it on a path in the android device. I can unzip the video content too, but i dont know where the video player is

searching for the content. Know somebody of you THE path or can i create my own path in the video player plugin? 

 

Thank you! 

Vuforia Video Playback on Android with Unity

April 17, 2017 - 11:24pm #5

Clarification:

 

in my previous post in the part -->

 

also follow the steps given on http://jon-martin.com/?p=597

in the script given on this page You need to make following changes

paths={

        "QCAR/yourtargets.dat",      //give the name of your image target database --> check StreamingAsset/QCAR folder

        "QCAR/yourtargets.xml",

        "QCAR/Unity.txt",       // remove this if only video is to be added

        "mymovie1.m4v",      // remove this also  --> replace with your file name like abc.mp4

        "mymovie2.m4v"      // remove this also   --> replace with  your file name 

       };

 

so in summary its 2 step process

1. Add correct file names in script given on http://jon-martin.com/?p=597

2. Change m_path in VideoPlaybackBehaviour.cs

Cheers ;)

Vuforia Video Playback on Android with Unity

April 16, 2017 - 11:03am #4

thanks a lot ... it worked. If videos are in streamingAsset  folder ... just add the line 

 

m_path = Application.persistentDataPath+"/"+ m_path 

in the script - 

VideoPlaybackBehaviour.cs script.

 

mVideoPlayer = new VideoPlayerHelper();



//this line of code helped!

m_path = Application.persistentDataPath + "/" + m_path;   //just add this line



mVideoPlayer.SetFilename(m_path);

 

also follow the steps given on http://jon-martin.com/?p=597

in the script given on this page You need to make following changes 

paths={

        "QCAR/yourtargets.dat",      //give the name of your image target database --> check StreamingAsset/QCAR folder

        "QCAR/yourtargets.xml",

        "QCAR/Unity.txt",       // remove this if only video is to be added

        "mymovie1.m4v",      // remove this also

        "mymovie2.m4v"      // remove this also 

       };

 

hope it makes it more clear

Vuforia Video Playback on Android with Unity

June 3, 2016 - 6:31am #3

Could you share more detailed explanation please, we have same problem?

Vuforia Video Playback on Android with Unity

September 16, 2015 - 3:08am #2

god damn i have my answer! You must add one line of code in the VideoPlaybackBehaviour.cs script.

 

        mVideoPlayer = new VideoPlayerHelper();

        //this line of code helped! 
        m_path = Application.persistentDataPath + "/whatever/" + m_path;

        mVideoPlayer.SetFilename(m_path);

 

Log in or register to post comments