Video player doesn't work in webgl
Hi ,
Im trying to set up a virtual expo with some video players on planes showing animations made by students.
The webgl build is hosted on a cors enabled server, and the video players are set to URL with the adress of the files on the server. The files do play when the server adres url is used directly in the browser. I've been reading up on such issues and made sure also a .htaccess file is available in all directories.
Here's currently the best working build https://piazza.me/vr
My problems : - There are multiple video players in the game, but most don't play. Results vary on computers & browsers.. This is the main problem atm. The only video that seems to work directly is warped as texture around a 3D object. The other 4 videos , being played on a plane object stay blank. This goes for the hosted version shared above ,as on a firefox webgl build running of my localhost.
This is the error i see in firefox browser console, and it builds up quickly : Error: WebGL warning: texSubImage2D: Source must not be null.
In chrome i see : f5c2d259-8b68-45bf-a94e-f819b35a9e67:8 WebGL: INVALID_VALUE: tex(Sub)Image2D: video visible size is empty
[.WebGL-00000200E4BC6230] GL_INVALID_OPERATION: Level of detail outside of range.
Can anyone please have a look at this project ? Thank you so much
Could be this problem: https://github.com/pixijs/pixi.js/issues/5996 When I try in Firefox the video's do show!
Answer by Wim-Wouters · Feb 19, 2020 at 02:48 PM
Following...
I have the same problem... video's hosted on same domain. You can see the video downloading in (F12) network monitor.
But they are not playing.
Platform: webgl /unity 2019.3
Errors: GL_INVALID_OPERATION: Level of detail outside of range. & WebGL: INVALID_VALUE: tex(Sub)Image2D: video visible size is empty
Answer by akshays2 · Mar 18, 2020 at 09:07 PM
The issue is already raised - https://issuetracker.unity3d.com/issues/webgl-videoplayer-is-not-rendered-in-webgl-builds-when-the-video-is-loaded-via-url
For the time begin, you can downgrade your project 2019.2 in order to make Video Player work in WebGL.
Answer by blabberbytes · May 18, 2020 at 10:10 PM
Any Luck?? I've having the same issue except my video wont play on a webGL build at all no matter the browser. Also downgrading to 2019.2 didnt work for me. I'm a noob, can someone tell me what im doing wrong?
Are you playing a video file or URL? Try adding the video as a strea$$anonymous$$g asset. Check your browser console for any errors.
Your answer
Follow this Question
Related Questions
Webgl build does not play video but editor does 0 Answers
Video Player and Web GL build not working 2 Answers
WebGl Video player set time not working 0 Answers
Unity WebGL video player on mobile 0 Answers
Streaming video camera input from WebCamTexture on mobile? (Possibly via WebRTC or websocket?) 1 Answer