Alpha maps?

For all the users of Twilight Render (V1 & V2), to ask questions and get started
bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Alpha maps?

Post by bb60 » Mon Sep 21, 2009 3:03 pm

Maybe I missed it in my brief overview, but I don't see a place for alpha maps in the Material Editor. I enjoy rendering 2D entourage with alpha maps. Can I use these with TR?

Ecuadorian
Posts: 1779
Joined: Fri Mar 20, 2009 3:43 pm
OS: Windows 7 Pro 64-bit
SketchUp: 7.1
Location: Guayaquil, Ecuador
Contact:

Re: Alpha maps?

Post by Ecuadorian » Mon Sep 21, 2009 3:11 pm

You don't need alpha maps, just transparent .PNGs. Keep the image unexploded for soft transparency, or explode it to use a "clippping" border instead. Try these:
http://www.forums.sketchucation.com/vie ... it=+alphas
Adam provided alpha maps for the benefit of V-ray users, but in Twilight you don't need them.
Last edited by Ecuadorian on Mon Sep 21, 2009 3:15 pm, edited 1 time in total.

bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Re: Alpha maps?

Post by bb60 » Mon Sep 21, 2009 3:14 pm

If I add the alpha map to my 2D landscape jpegs in Gimp, can I save them as pngs for this purpose? My experience is that if I explode pngs in SU, they gain the bordering rectangle and so need an alpha map to get rid of it in the rendering.

Ecuadorian
Posts: 1779
Joined: Fri Mar 20, 2009 3:43 pm
OS: Windows 7 Pro 64-bit
SketchUp: 7.1
Location: Guayaquil, Ecuador
Contact:

Re: Alpha maps?

Post by Ecuadorian » Mon Sep 21, 2009 3:17 pm

Of course, I've done it a few times in GIMP but I can't remember the process. I think you had to load both as layers, select the white part of the alpha map, add an alpha channel to the color layer and set it to "selection". I believe in Photoshop it's more straightforward.

Fletch
Posts: 12906
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: Alpha maps?

Post by Fletch » Mon Sep 21, 2009 3:21 pm

When you save the PNG be sure "use transparency channel" or whatever your photo editor has is checked.
Use this in your material, and it will be used as the clip map. (Clip Map = anything 50% opaque and less will be clipped to zero visibility, anything 51% opaque and above will be visible)

bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Re: Alpha maps?

Post by bb60 » Mon Sep 21, 2009 3:27 pm

Thanks! I will experiment.

bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Re: Alpha maps?

Post by bb60 » Mon Sep 21, 2009 8:16 pm

I tried saving a sample jpeg as a png in Gimp and I tried applying the alpha map to the image as a layer mask (the technique I use in post-production) and saving this as a png. I imported the samples into SU, exploded them and made them components, and they rendered out with white rectangles. What am I doing wrong?

Ecuadorian
Posts: 1779
Joined: Fri Mar 20, 2009 3:43 pm
OS: Windows 7 Pro 64-bit
SketchUp: 7.1
Location: Guayaquil, Ecuador
Contact:

Re: Alpha maps?

Post by Ecuadorian » Mon Sep 21, 2009 8:41 pm

First, make sure that you didn't have any background layer active when you exported your png. You should see a checkerboard pattern behind your object in your Photo editor if everything is right.

Then, when you're going to export it, there must be an option somewhere to activate png transparency, make sure to tick that box.

If your png file is indeed transparent, when you view it as a "slideshow" in Windows XP the background should change to black.

bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Re: Alpha maps?

Post by bb60 » Mon Sep 21, 2009 8:58 pm

Thanks for helping! I add the alpha map to the jpeg as a layer mask, and the background is transparent. However, to get it from the layers palette I have to move it to a blank new file. Maybe this is wrong. Also, in Gimp I can't find any box to activate transparency. Twilight looks really great, but I need to solve this issue before I can use it!

bb60
Posts: 16
Joined: Sun Sep 20, 2009 10:01 pm

Re: Alpha maps?

Post by bb60 » Mon Sep 21, 2009 9:24 pm

O.K., I think I have it, for anyone who's interested. Open the image in Gimp and make a duplicate>Layers, Add Transparency>select the white background around the image and delete it, then turn off the eye on the original image in the Layers dialogue (the background will be a checkerboard) and save it as a png. Then import it into SU, explode it and make it a component (it will have a black line border but this will disappear in the render).

Thanks for your help, everybody!

Post Reply

Who is online

Users browsing this forum: No registered users and 34 guests