0
$\begingroup$

I'm trying to apply two materials to an object -- one of them is a transparent PNG graphic which is supposed to be placed on top of another. What I do is select the object, go into Edit Mode, create a new material slot, select the two, and assign them. However, when I assign the PNG material, the one below it disappears -- I can see inside of my object.

enter image description here

enter image description here

Here I have the PNG graphic layered on top of the purple color provided by that second BSDF. However, when I try attaching the image texture to the base color of this BSDF, the texture does not cover the entire face of the object. Instead, it results in what is seen here:

enter image description here

The face of the object is black, displaying the pattern in a box rather than covering the whole object.

$\endgroup$
1
  • $\begingroup$ "...select the two, and assign them" - how do you actually do that? You can only select one material slot at once, not two. And each face of an object can only be assigned with one material. $\endgroup$ Commented May 3, 2021 at 5:58

2 Answers 2

0
$\begingroup$

You just need 1 material.

In the shader editor use this node setup and you get what you want:

enter image description here

UPDATE:

setup with two images:

important: the "upper" image must have pixels with alpha < 1 inside of the png (in my case here the "toppng")

enter image description here

$\endgroup$
13
  • 2
    $\begingroup$ Not only does he need just one material, but it's simply not possible to apply more than one material per face in Blender. $\endgroup$ Commented May 3, 2021 at 5:55
  • $\begingroup$ Thank you for your help. You're right that you can apply only a single material to a face at a time, I must have been confused. Unfortunately, your model is not working for me: - When I connect my alpha node to the Mix shader factor node, my PNG turns black - My second material is not a BDSF, it is an image texture. I tried creating an additional image texture, along with another BDSF, to connect it, along with the PNG + its own BDSF, to the mix shader. But this does not produce the desired results. Please see the screenshot I attached in my original post. $\endgroup$
    – Matthew
    Commented May 3, 2021 at 20:35
  • $\begingroup$ @Matthew You have to plug the Alpha from the texture into the Fac input of the Mix Shader node, as Chris has shown in this answer. $\endgroup$ Commented May 3, 2021 at 21:42
  • 1
    $\begingroup$ i updated my answer. unfortunately you did not include your textures...next time before you upload the blend file, please use file-> external data -> pack all into blend $\endgroup$
    – Chris
    Commented May 4, 2021 at 6:20
  • 1
    $\begingroup$ @Matthew: this site tries to help people who have same problems to quickly solve this. Of course - you don't have to say what the reason was. And of course you don't have to check an answer as correct. But it would be nice - if you know the reason for your problem - if you write an own answer and so others can find your solution too. Because you got help - hopefully you will help others. $\endgroup$
    – Chris
    Commented May 5, 2021 at 5:03
0
$\begingroup$

Here's the node setup to lay a semi-transparent PNG over another, tiled image texture material.

enter image description here

$\endgroup$
2
  • $\begingroup$ Congrats - you copied my answer. It is the same setup I did - just with colors instead of shaders. Oh man....🤦🏻‍♂️ $\endgroup$
    – Chris
    Commented May 6, 2021 at 2:35
  • $\begingroup$ @Chris Well, for whatever reason your setup wasn't working for me. Perhaps I misunderstood along the way. Thanks for your help $\endgroup$
    – Matthew
    Commented May 10, 2021 at 21:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .