Quantcast
Channel: Babylon.js
Viewing all articles
Browse latest Browse all 388

Assets Manager and Video Textures

$
0
0

Hi,

 

I'm running into an issue regarding the Assets Manager and the Video Textures :

 

When loading a sound, here is an example of code that works very well, using Assets :

var binaryTaskSound = assetsManager.addBinaryFileTask("s1 task", "sounds/sound1.mp3");
binaryTaskSound.onSuccess = function (task) {
	music5 = new BABYLON.Sound("s5", task.data, scene, soundReady, { loop: true});
};

Now when I want to load a Video Texture using the same method, it doesn't not seem to work anymore :

var binaryTaskVideo = assetsManager.addBinaryFileTask("v1 task", "videos/Cocoon720p-Synced.mp4");
binaryTaskVideo.onSuccess = function (task) {
	var videoTexture = new BABYLON.VideoTexture("video", [task.data], scene, false, true);
};

Viewing all articles
Browse latest Browse all 388

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>