- Home /
Why isn't the background on this material showing up as transparent?
So this is a question that I'm seeing pop up a lot, and yet none of the answers I've found are working for me.
I have this PNG image with an alpha channel:
Which I imported into Unity, setting it to use input texture as alpha source, and setting alpha to transparent:
The image looks like it is being rendered the way I want in the preview. However when I apply it to a material, using a transparent shader like so:
The end result suddenly has a blue background, like so:
There must be something simple I'm missing. Does anyone have any idea why this is happening? I just want the background to be transparent, the way it is showing up when I first import the image.
Thank you!
Answer by GrayRabbitGames · Jul 28, 2017 at 09:33 PM
As it turns out, the solution was to change the shader to "unlit / transparent". Worked like a charm. Only problem is I also wanted to fade this object out using an alpha channel, but unlit / transparent won't allow me to access one, since it doesn't have a color setting. Oh well...
Try out my answer. Worked like a charm on my setup with the same problem, and it doesn't require you to use a different shader.
Hi there Fortis,
I'm trying it now, and unfortunately it's not fixing the issue. While it does allow me to use the metallic slider as a means of controlling the alpha, there is still the blue background on it that shouldn't be there.
Thanks anyway - still not sure what exactly the issue is, but the unlit/transparent just seems to work. Even though I'm sacrificing the ability to fade it out.
Answer by rawb86 · Jul 28, 2017 at 08:55 PM
Does it work like intended if you change the shader to "Standard (specular setup)", make the specular all black and set Smoothness to 0?
Answer by FortisVenaliter · Jul 28, 2017 at 09:00 PM
Change the Metallic Smoothness Source from "Albedo Alpha" to "Metallic Alpha".
Right now it's using the alpha channel in your texture to determine smoothness. For some reason, this seems to discount it from being used as a transparency channel.
Answer by fede9948 · Jul 28, 2017 at 09:57 PM
I think what you are looking for is the standard shader set to "Fade" instead of transparent. You could turn off specular highlights and reflections to have only your graphic displayed on the object. You can modify its alpha value to fade it in/out.
Answer by TheWrongJohn · Apr 16, 2021 at 09:37 PM
These setting seem to be working for me, at least for now :-)
Your answer
![](https://koobas.hobune.stream/wayback/20220612131416im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Using Multiple Tiles for Textures 0 Answers
Standard Asset water material is pink 4 Answers
Creating a Material from shader string 2 Answers