New To The Forum? Click Here To Read The How To Guide. -- Developers Click Here.

Playing large video files in Gear VR in Unity project

RGB3D-RobertRGB3D-Robert Posts: 5
I'm creating a Gear VR android app that plays a large 30 minute video. I have read that I should not use the StreamingAssets folder, but I don't see any information about what I should be using instead. If I put the video in Assets/videos it is not included in the android build. Should I be using the resources folder or is there another way to include the video? (My project is also on iOS, but I'm currently not having any problems on that platform.) I have read that the PersistentDataPath folder can be used, but I don't know how to get my video into that folder when from unity. I don't want to copy the video there and have two 600mb files when only one is used.


  • imperativityimperativity Posts: 1,697 Oculus Staff

    Have you considered using asset bundles to accommodate this large file?

    What’s in an AssetBundle?

    Good question, actually “AssetBundle” can refer to two different, but related things.

    First is the actual file on disk. This we call the AssetBundle archive, or just archive for short in this document. The archive can be thought of as a container, like a folder, that holds additional files inside of it. These additional files consist of two types; the serialized file and resource files. The serialized file contains your assets broken out into their individual objects and written out to this single file. The resource files are just chunks of binary data stored separately for certain assets (textures and audio) to allow us to load them from disk on another thread efficiently.

    Second is the actual AssetBundle object you interact with via code to load assets from a specific archive. This object contains a map of all the file paths of the assets you added to this archive to the objects that belong to that asset that need to be loaded when you ask for it.

  • oculus_gaboroculus_gabor Posts: 22 Oculus Staff
    Gear VR supports 1 expansion file, up to 4GB. We have some documentation in the works on it. For now, this page will get you started:

    You have to adhere to androids naming convention of:
    So for example, if your app package name is and this is V1 of your app, the extension file would be
    You can't upload the extension files with the web interface, you'll have to use the command line tools from here

    The command to upload will look something like this:
    ovr-platform-util upload-gear-build --app_id <app id> --app_secret <secret> --apk <apk path> --obb <external data file path> --channel alpha --notes "Uploading apk and external data"
Sign In or Register to comment.