Forum: Carrara


Subject: How to use a plane for a 2d image

3doutlaw opened this issue on Mar 05, 2011 · 5 posts


3doutlaw posted Sat, 05 March 2011 at 10:51 PM

There is a lot of talk about this in a lot of threads, but I cant find a how-to in the user manual or online help guide.

What I have done is to create a plane, go to the shader room, and make Top Shader -? Flat Mapping, then a Texture Map and chose a PNG of a tree.  That made the tree appear on the plane, but the tranparency did not work quite right (a lot of white in there) and the test render showed nothing, just a blackness.

I also tried a multichannel, with texture, and an alha channel...nope

I also tried a JPG with white, and clicking white is invsible, and nope again. 

I have not gotten anything to show up in a render or test render.  Mixed results in how it shows in the textured preview.

Is there a quick how-to on this?

(once I get this, the next steps are face the camera and produce a shadow...but I will experiment a little to see if I can figure those out)


Kixum posted Sun, 06 March 2011 at 3:42 AM

I'm assuming that you're trying to make a 2d billboard of a tree?

If so, you need two images.  The first is a picture of the tree.  Then you need a mask (the same picture of the tree with white where you want the parts of the tree picture to appear and black where you don't want it to appear.

Then, put the tree into the color channel and then put the mask into the alpha channel.  You can also do this with the transparency channel but it's a tweense more tricky.

If you still get nothing, there's a chance that you're looking at the plane from the wrong side.

Try that and let us know if that works.

-Kix


3doutlaw posted Sun, 06 March 2011 at 12:38 PM

That works...yea!  Last night I tried this but had the black/white backwards...ugh.  Thank a LOT!  :)

So now I have that working, I see that I need Multi-channel versus Flat Mapping to get the Light Through Transparency working for a correct shadow.  Works...yea!  :)

That leaves the Point At modifier.  That works, but to keep it from looking up in the air, I set a Ball Joint constraint.  Is that the correct method?  (what is odd, is that for the ball joint constraint, if I lock X and Z, that locks the actual object rotation of X and Y?)

That leaves a final question related to the Shadow.  Is there a way I can have the shadow always act as if the billboard if facing the light, but have the object itself face the camera?  In that way, if I look at it from the side, I see the tree, but the shadow is appropriate.

Thanks again!

 


Kixum posted Sun, 06 March 2011 at 8:14 PM

That's a really good question (about the shadow that is).

There used to be an option to select so that an object would interact in the scene just like normal but it would not be rendered.  In other words, it would cast shadows and provide GI interaction and all that stuff but it would not show up in the render.

I've actually been trying to find that option in the last few versions and it's either been removed or it's gone.  So here are my recommendations.

1.)  If you can find that option (does not appear in render), then add a second plane just like you have it but set the point at behavior to point at your light source.  Then it will cast the shadow the way you're talking about.  Put both these "trees" into a single group and then one of the trees will point at the camera and the other will point at the light and you will get a render of the tree with the correct shadow.  Also, turn off cast shadows for the plane which is pointing at the camera so just the shadow for the shadow tree is working.

2.)  If I'm just nuts and that option can't be found, what you can do is put three to six of these planes in a group and have them rotated by an equivalent amount (90 degrees for two planes, 60 degrees for three, etc.) and sort of make a cheapy tree that might look ok from a distance.  I have no idea how that would look though.  Video cames have been doing it for a long time but it might look really dorky.

3.)  Last but not least, you can actually use the Carrara trees.  If you use the replicator and set up the base tree correctly, it's not too hard and it looks pretty good.

-Kix


Kixum posted Sun, 06 March 2011 at 10:44 PM

Hey I was wrong on this.

What I was thinking of doing uses an old trick that won't work for you.  Here's the old trick.

You make a shape, give it no color, set it to 100% transparent, and no light interactions when transparent.  Then you uncheck the light through transparency and sure enough, you get a shadow of an object that you can't see.  The thing is, the way we're working this would dork up the plane that you're using so that's not going to work.

Sorry about that.

The other option is to actually make a 2D shape that is the same as your tree image and map the PNG to it.  Then you could do what I suggested above (two tree shapes, one pointing at the camera and one at the light).  That will work but you would have to draw the tree shape and get a 2D plane setup for it.  It's quite doable but an extra step that takes some time.

-Kix