Jump to content
EllieAnne Silverfall

Help! casting wrong shadow!

Recommended Posts

Help! I didn't have this problem before and I have no idea why it is happening now. Perhaps one of you can help?? 

I have an item I am making and I have a plane that will have an image of a leaf in the center and transparent around it. I want the leaf only to cast a shadow onto the object behind it. However, every time I try (and I believe I have everything set correctly regarding alpha and shadows), I end up with a shadow from the entire plane, not just the leaf. It seems to be a problem on the object behind, because the plane renders correctly. The only way I can make it go away is to make the plane cast nothing. I want the leaf shadow, so this doesn't work for me. 

Please help?? I'm at a loss. I have googled and googled and set everything the same as I read, to no avail. 

Share this post


Link to post
Share on other sites

I can't help with Blender, but how about just cutting the leaf out of the plane, and get rid of the tranparent sections entirely for baking?

Share this post


Link to post
Share on other sites

Because I need to do this with several differently shaped leaves. If I can get it to do what it is supposed to do, I'll have less work and less faces. Perhaps, if I get no success, I'll have to do that though. 

Share this post


Link to post
Share on other sites

@Pamela Galli

It can be done in cycles (I've watched videos), and I've read it can be done in render, but I haven't be able to accomplish it yet. I'm supposed to only need to enable "receive transparent" on the object I want the shadow to fall on, and poof, it should be there. Alas, I keep getting the shadow for the whole plane. I have watched tutorials and read and they all say the same thing. Object one (the one with the alpha) set Ztransparency, alpha=0 on materials, then on texture, use alpha. On object 2 (the one that collects the shadow), set materials to receive transparent. It is supposed to be that easy, I am getting the shadow I want, but I am also getting a gray shadow from the alpha, that I don't want. The only way I can do it without the gray shadow is to set object 1 to not cast. But then I get no shadow, and I don't want that either. 

But, then again, maybe I am wrong and am misunderstanding the whole thing. 

Share this post


Link to post
Share on other sites

@Pamela Galli

Ok... I thought more about your wording. Maybe I am misunderstanding what I am watching/reading. You mentioned baking specifically. and I get what you are saying. Maybe I will need to just make the cutouts of the leaves and stop trying to use the alpha texture. sigh. Or, alternatively, turn off casting. sigh again. 

 

Share this post


Link to post
Share on other sites
2 hours ago, EllieAnne Silverfall said:

@Pamela Galli

It can be done in cycles (I've watched videos), and I've read it can be done in render, but I haven't be able to accomplish it yet. I'm supposed to only need to enable "receive transparent" on the object I want the shadow to fall on, and poof, it should be there. Alas, I keep getting the shadow for the whole plane. I have watched tutorials and read and they all say the same thing. Object one (the one with the alpha) set Ztransparency, alpha=0 on materials, then on texture, use alpha. On object 2 (the one that collects the shadow), set materials to receive transparent. It is supposed to be that easy, I am getting the shadow I want, but I am also getting a gray shadow from the alpha, that I don't want. The only way I can do it without the gray shadow is to set object 1 to not cast. But then I get no shadow, and I don't want that either. 

But, then again, maybe I am wrong and am misunderstanding the whole thing. 

 I Should have said that I don’t know any way to make the shadow of a texture in blender. 

Share this post


Link to post
Share on other sites

Hi :)

 

On 11/1/2017 at 9:53 PM, EllieAnne Silverfall said:

It can be done in cycles (I've watched videos), and I've read it can be done in render, but I haven't be able to accomplish it yet.

A simple way to do it in Cycles (maybe) is :

1: In Gimp or PhotoShop convert your leaf texture to a Black mask as in the  screenshot below.

2: In Blenders Cycles Node editor swap out your leaf texture for the new mask texture,  see screenshot.

3:  and insert a Transparent BSDF node between the Image Texture node and the Material Output node.

  Note : varying the size of the lamp  will change the softeness of the shadows  ( smaller the lamp the sharper the shadows will be ).

59fb9a6f29c0a_Blenderleafshadow.thumb.png.cdefb60a6065ea8c6215c8fbbf096167.png
 

If needed you can find the .belnd file here :    http://pasteall.org/blend/index.php?id=48209

 

As you have already mentioned I am sure you can do this in Blender without having to first create the mask in Gimp / PS.  Perhaps you could  post the link to the Cycles  video tutorial that you found showing how this is done.

 

 

Share this post


Link to post
Share on other sites

I gave up on it for now. It'll be something I play with later. BTW, I was under the impression that we couldn't use cycles for SL mesh, only blender render. is this not true? Frankly, I found cycles really easy to use and might prefer going back to it.

Share this post


Link to post
Share on other sites

SL does not know what type of rendering or texturing you use, just the model format.

Edited by Pamela Galli

Share this post


Link to post
Share on other sites

 

I finally got around to asking Google how to do this wholly within Blender :

Apparently using Cycles it has to be done in two steps.

Step1,     Bake out the shadow texture :

5a11af9f61a07_Bakeshadowsofleaves.thumb.png.9bbbfabb003d38315f4a13a9c29f076f.png

 

Step 2,      Use the compositing nodes to remove the white background in the baked shadows texture :

5a11afccb637f_Copositingbaketexture.thumb.png.429d011655fb3590cd2219ccf4d08d46.png

If you add a Maths node set to Multiply you can vary the darkness of the leaf shadows.

 

See here for more details : 

Step1

 

and here for Step 2      https://blender.stackexchange.com/questions/41555/how-do-i-bake-a-transparent-shadow-texture-using-cycles-bake

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...