- Home /
Can we load video from Asset bundle ?
Hi, I am working on AR application in unity and I have a huge amount of videos as a target, what i need is to build asset bundle of those videos and load them from local Android directory .
or
Is there another way to do this ?
Answer by UnityCoach · Oct 23, 2018 at 07:50 AM
As an alternative, you can put your videos in a StreamingAssets folder at the root of your project, then stream the videos from there using the URL option. Asset Bundles are useful for assets you need to "package", such as models, textures and the like. With videos, streaming is to me the best option.
Thanks UnityCoach, But I have huge amount of video data and i think if I put all stuff in strea$$anonymous$$g assets folder it will increase size of my application more than 1000 $$anonymous$$b's.
I see. What you can do, is to download the videos from an online url, using WWW to a local path using persistentDataPath for example. You can also keep a list of available videos in a Json file somewhere on the server so you can easily update them. That said, you can also put videos in an Asset Bundle. But if you want control over individual video files, say to have the option to keep it local or remote, you'd need a bundle for every video.
Your answer
Follow this Question
Related Questions
No AssetBundle.mainAsset with BuildingAssetBundles in 5.x ? 2 Answers
Does New AssetBundle Build System in Unity 5 require separate packages for separate platforms 1 Answer
Asset Bundle dependencies already in build 0 Answers
Using asset bundles as DLC content (additional maps and levels)? 0 Answers
Load scene from assetbundle 1 Answer