Play video .webm with alpha - vp9 #7175
Replies: 6 comments 6 replies
-
Try this one: PIXI.glCore.GLTexture.prototype.upload = function(source)
{
this.bind();
var gl = this.gl;
gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, this.premultiplyAlpha);
var newWidth = source.videoWidth || source.width;
var newHeight = source.videoHeight || source.height;
if(newHeight !== this.height || newWidth !== this.width || source.videoWidth)
{
gl.texImage2D(gl.TEXTURE_2D, 0, this.format, this.format, this.type, source);
}
else
{
gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, this.format, this.type, source);
}
// if the source is a video, we need to use the videoWidth / videoHeight properties as width / height will be incorrect.
this.width = newWidth;
this.height = newHeight;
}; |
Beta Was this translation helpful? Give feedback.
-
I tried both ways. Either edit both pixi.js or add a patch and insert it into the index. If I change pixi.js to that function, it gives me black screen during testing. A total black screen, i can't do anything. If I insert the patch and put it in the index, the game starts and i see the test room, but the alpha doesn't seem to work, unfortunately, if i start the video. Tell me if I made the right steps, in theory yes ... it only change a couple of things in the end ... Did i miss something? I've attached some screenshot (first two about the Pixi patch, and other two about the change that i made... |
Beta Was this translation helpful? Give feedback.
-
@ivanpopelyshev Do you have any news? :( You sent me a code, but it doesn't work in a Project... |
Beta Was this translation helpful? Give feedback.
-
@ivanpopelyshev I'm continuing to place hope in your holy help... |
Beta Was this translation helpful? Give feedback.
-
Please, someone can help?... |
Beta Was this translation helpful? Give feedback.
-
Hello Guys, can youhelp me and resolve this issue, please? A good soul ç_ç I need your help... PLEASE T_T |
Beta Was this translation helpful? Give feedback.
-
Hello guys,
i really don't understand why i can't reproduce correctly a video that i made on adobe after effect RGB+Alpha, rendered in quicktime .mov and recoded in .webm keeping Alpha.
I'm trying to reproduce this video in RPG MAKER MV, Pixi version 4.8.9
I really don't understand.
I found a similar thread and i read a lot of stuff about this problem. A similar thread was this: #4190
Someone connected it to another thread: #4089
But i really don't understand what i must do.
Please, help me. Is it so difficult play a video without background? T_T It always show Black background.
I would love to create transparent background video animations.
If you need other informations, please tell me.
Thanks to the good soul who will help me to solve this problem.
Beta Was this translation helpful? Give feedback.
All reactions