[SOLVED] Uploading and playing Video


Does anyone know if it’s possible to upload and play a video directly from the Playcanvas editor? I tried following the video textures tutorial but it seems to require a video to be hosted on an external site, which I don’t have. I tried uploading a .mp4 file to Playcanvas, but it imported as an audio asset, and I don’t know how to play the visual part.


[SOLVED] Video in PlayCanvas Project
Audio Settings not in Editor

Even though PlayCanvas editor thinks it is audio, it doesn’t process/modify the file in any way so it is still a video file.

I’ve made a sample project showing a video that I’ve uploaded to PlayCanvas and playing it to a texture: https://playcanvas.com/editor/scene/574109


Thanks so much, worked like a charm :grinning:


Hi Yaustar,

I get this error using your code

[launch.js:7535]: Uncaught TypeError: Cannot read property ‘split’ of undefined

TypeError: Cannot read property ‘split’ of undefined
at console.error (https://launch.playcanvas.com/editor/scene/js/launch.js:7535:36)
at ResourceLoader. (https://code.playcanvas.com/playcanvas-stable.dbg.js:37650:23)
at AudioContext.error (https://code.playcanvas.com/playcanvas-stable.dbg.js:38065:7)

I noticed your project settings has Audio, mine doesn’t, so I can’t enable legacy audio

Is there a workaround for the current playcanvas editor online?

Or do I need a special tier account?



I don’t get any errors running my old project. Can you send a link to yours that is showing this error please?

I don’t know what you mean by this?


No worries, I figured out the issue. The mp4 video I uploaded was corrupt. The real issue is that I can’t load videos as textures on my iPhone so I thought loading local videos instead of cross-domain videos would solve the issue but I was wrong. Although local videos may work on full-screen on iPhone, mapping it onto a texture doesn’t work. I have yet to see a working example of this. If you know of any PlayCanvas developer that can give me an example of a video texture that I could load and see work on my iPhone, please let me know. I can even pay for them to debug my code. Need to fix this issue as soon as possible so that I can continue with the classically animated video production (that will be added as textures within my game).


I’m afraid I don’t have a iOS device to test with. The thing to note that I think both iOS Safari and Android Chrome prevent autoplaying or at the very least prevent audio from video autoplaying without some user interaction (like a tap or a click on the screen).


Actually, can you check this published build please on iOS? https://playcanv.as/p/rCIoFmmr/