-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Transparency #4
Comments
What operations do not leave transparency? I think this is due to existing shaders that write a value of 1 to the transparency buffer. |
not sure what you mean, this is my code that i have used along side your script - Texturity.initGL('webgl2', { alpha: true, antialias: false, depth: false } );
var fastCanvas = new Texturity.Canvas(textureSize, textureSize);
var texture = Texturity.loadTexture(img);
var previewImg = fastCanvas.drawTexture(texture, 0, 0, nodeTextureSize, nodeTextureSize).toSrc();
node.imgDiv.style.background = 'url('+ previewImg +')' |
Ok, I got it. Seems like drawTexture() write to alpha channel value 1.0 independently to image. I'll correct it |
just wondering, did this get updated? forgot about this issue haha |
Yes, I have a busy month :) |
no worries, just wanted to show this thread wasnt inactive :) is it updated here? doesnt seem to be different for me? no rush though! isnt a show stopper bug for me, im just not competent enough to fix it myself haha |
I mean I forgot about this too. No updates |
You can try to replace 1.0 with a certain color value in the last parameter of vec4 |
if you mean this line i did actually try that with no luck, unless i am miss understanding? |
No, inside the |
ok so with your guidance i did a bit of digging / learning and found / changed this line to the following -
if youre happy with this we can close this issue, i have created a pull request :) |
Hi,
after successfully implementing texturity into my project, for some reason I cant get my textures to display their alpha channel?
obviously ive seen the code
and also digging deeper -
when turning alpha to true with using
it doesnt seem to do anything for me?
been looking online and all i can really find is this and a few other sites that say similar things but having tried most of it, doesnt seem to help me at all unless I am doing it wrong?
many thanks
The text was updated successfully, but these errors were encountered: