[SOLVED] PNG textures have a black edge

Hi, all.
I am using png textures with holes, and they have a black outside in the viewport but not in the actual texture file. Is there any way to fix this?
0 (1)

Hi @Codeknight999!

Maybe you need to change some texture or material settings.

Can you share a sample project please?

Sure! PlayCanvas 3D HTML5 Game Engine you can make any necessary
adjustments

Hi @Codeknight999,

I didn’t take the time to check out the UV’s on the models in question, but if I had to guess, the artifacting you’re seeing has to due with the opacity map not having enough padding around the transparent parts, resulting in the weird islands you see once mipmaps are created. Raising the Alpha test on your material reduces the artifacts, but also appears to create holes that you may not want. I found a decent balance by changing the opacity blend mode to alpha, and setting alpha test to 0.456. Outside, of that, I would consider revisiting your textures and either increasing the padding in the desired places, making a dedicated opacity map, or overall raising the resolution of the textures.

I hope this is helpful.

@Albertos found the issue. @eproasim it was the ocapacity, I had to change it from none to alpha. Thanks to @Albertos for helping and thanks @eproasim for the suggestion!

1 Like