VideoClip and AssetsBundle problem (5.6)
Hi, I'm trying to make a system that let me download VideoClip (5.6) form AssetsBundle.
I'think there's no problem during asset download process. I'm using the AssetBundleManager that can be found on Bitbucket and suggested in the doc. (all the log tel me that the dowload end successfully).
But when i set the downloded VideoClip to VideoPlayer Unity log me an error like this:
I've try other platform but is almost the same, only change the reader.
Like Android: " AndroidVideoMedia: Error opening extractor: -10000"
This is the code (C#) that i use to set the clip (quite simple):
// Get the asset.
VideoClip clip = request.GetAsset<Object>() as VideoClip;
if (clip != null) {
Debug.Log(clip.ToString() + " | "+ clip.length);
videoPlayer.clip = clip;
}
Some one have and idea of what could be the problem?
I have try to make a bundle not compressed, but nothing change.
I've try the video without bundle (directy) and work fine so is not a video problem.
Answer by MiteshJSavaliya · Jun 06, 2019 at 03:31 PM
private void Awake()
{
Caching.compressionEnabled = false;
Caching.ClearCache();
}
Answer by AlbertoSalietoStarloop · Jun 23, 2017 at 08:26 AM
I got same problem too but i can't find a better solution. Currently I'm downloading the video files using www and loading them from the streaming assets folder, but i'm still waiting for a videoplayer fix.
Also follow this post to get updated. https://forum.unity3d.com/threads/load-videoclip-in-assetbundle-on-android.466850/
Any Updated on this issue? I'm facing the same problem
@AlbertoSalietoStarloop @$$anonymous$$romos92
Still buggy...
"AndroidVideo$$anonymous$$edia OpenExtractor unable to open archive [...]" UnityEngine.Video.VideoPlayer:INTERNAL_CALL_Prepare(VideoPlayer) UnityEngine.Video.VideoPlayer: prepare() (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/modules/Video/VideoPlayerBindings.gen.cs:175)
Tested on Unity 2017.2.0f3 (64-bit)
Your answer
Follow this Question
Related Questions
How do i play a video from the web, on my unity game? 0 Answers
Video Player: 'Material Override' Missing? 0 Answers
Compress AssetBundle will build assetbundles 0 Answers
Problem with Asset Bundles in Unity 2020.3.30f1 1 Answer
How can i play various videos on one gameobject and switch them by pressing a button? 1 Answer