Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

creating alpha channels for fur

Stasey Oller
Registered User
Join date: 19 Jun 2009
Posts: 1
11-26-2009 02:33
Hello all!

im having a bit of delay on my christmas outfit. i created a fur texture, and was told i needed to make the actual fur texture the alpha channel. and to do so, i would need to

make a copy of my fur texture, and put a black background against it,
then i would merge the copy fur texture and the black background together,
turn off the original fur texture
then cut the copy'd fur texture with the black background
then paste it into a new alpha channel. (all in photoshop cs3)


turn off the new alpha channel, and turn the other ones back on, then turn
off my copy fur texture and turn the original fur texture back on.


but everytime i load it in as a targa32 into SL, it seems to have an opaque light
white film around my fur ball, verses it being completely transparent??
i even tried to create a simple alpha channel with the marching ants as i would
do when creating a basic shirt etc.

please, any help would be greatly aprpeciated!!!
ive tried many times, and seem to fail fur is much more complicated than
clothes i suppose. or im a total blonde.
happy turkey day everyone!!!
Papalopulus Kobolowski
working mind
Join date: 11 Aug 2006
Posts: 326
11-26-2009 03:21
easy way:

dont put any background and save it as .png

hard way :

work with alpha channels(better).

http://www.axialis.com/tutorials/tutorial-misc001.html
_____________________


RAW terrain files - terraform your SIM!!
http://www.wishland.info/
PD:the wiki its your friend ;)
http://wiki.secondlife.com/wiki/LSL_Portal
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-26-2009 03:25
From: Papalopulus Kobolowski
easy way:

dont put any background and save it as .png

hard way :

work with alpha channels(better).

http://www.axialis.com/tutorials/tutorial-misc001.html




club haha..i like the easy way =)

so i create an alpha channel with the orginal fur as you would with clothes?
then save as png

sorry to sound like im from the turtle club
Ephraim Kappler
Reprobate
Join date: 9 Jul 2007
Posts: 1,946
11-26-2009 03:48
For the best effect, the background colour of your image should be similar to the colour of the fur texture. The background colour will always show as a 'tide-mark' around the visible area of the image and it will be more noticeable as resolution is decreased. If the fur texture has a range of colours, say yellows, reds and browns, then the background colour should be fairly representative of the colours around the edge of your texture.

Other than that, the procedure you are describing seems a bit cackhanded if you don't mind me saying so. Are you using Photoshop? I use a very old version of the program where the process is very simple and it wasn't much different in CS2 when I last used it. Try this in CS3 and see if it works for you:

Fill the layer immediately under the fur layer with an overall reasonably similar colour. Ensure that your selection tools are set to 0 pixels or at least some fairly small value like 0.5 if you want to feather your texture slightly. Load the fur layer as a selection. Invert the selection. Go to channels and create a new alpha channel. Mask off the background in the alpha channel by hitting delete. Flatten the image and save it as a 32-bit TGA file.
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-26-2009 03:50
yes. my way is not working. so call it what you want....hee hee. i dont mind.
im going to try that out now. my fur is white. so i will fill it with white.
thanks so much. im off to try your helpful tips out now
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-26-2009 04:11
From: Ephraim Kappler
Fill the layer immediately under the fur layer with an overall reasonably similar colour. Ensure that your selection tools are set to 0 pixels or at least some fairly small value like 0.5 if you want to feather your texture slightly. Load the fur layer as a selection. Invert the selection. Go to channels and create a new alpha channel. Mask off the background in the alpha channel by hitting delete. Flatten the image and save it as a 32-bit TGA file.



So I filled the layer underneath the fur, white, because the fur is white.
i went to *image*pixel aspect ratio and made it 0
i selected the fur as a selection, and inverted it.
i went to the channels, created a new channel, and hit delete on the background.
..i flattened the image, and saved it as a 32 bit tga....

and now my fur is completely transparent when i uploaded it into SL.
ive created a transparent texture...instead of a fur texture without the opaque
box around it...what am i doing wrong?
Ephraim Kappler
Reprobate
Join date: 9 Jul 2007
Posts: 1,946
11-26-2009 04:39
From: Jill Ordinary
what am i doing wrong?

If the entire texture is transparent, then you haven't masked the alpha channel with any part of the image shape at all. Check that you have only *one* alpha channel after the red, green and blue channels when you save the file. That is the channel you should have masked with your selection.
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-26-2009 04:46
you are correct. i am looking at the new alpha channel now,
and i didnt mask it with the shape of my fur ball..doing so now. *crosses fingers*
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-28-2009 15:04
From: Ephraim Kappler
If the entire texture is transparent, then you haven't masked the alpha channel with any part of the image shape at all. Check that you have only *one* alpha channel after the red, green and blue channels when you save the file. That is the channel you should have masked with your selection.



So im still getting a transparent image, after i masked the alpha channel with my image.
i copy the image, and paste it into the alpha channel after deleting the black areas of the alpha channel, and still, i am getting a completely transparent image when uploaded to SL. I don't know what im doing wrong. Fur is frustrating..help pleasE? Sorry im slow :/
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
11-28-2009 15:23
From: Jill Ordinary
So im still getting a transparent image, after i masked the alpha channel with my image.
i copy the image, and paste it into the alpha channel after deleting the black areas of the alpha channel, and still, i am getting a completely transparent image when uploaded to SL. I don't know what im doing wrong. Fur is frustrating..help pleasE? Sorry im slow :/

Your alpha channel image should have white areas for parts of the design that should be opaque in the final product and black areas for parts that should be transparent. Any areas that are gray will be translucent. The darker the gray, the more transparent they will be. If that's not what your alpha channel image looks like, you've done something wrong.

I don't know what you mean by "deleting the black area of the alpha channel." The mask layer you create as you are defining the shape of your fur piece should look just like the alpha channel does, except that the mask should generally have cutout areas where you want the end product to be opaque. Once you have created a mask and generated the alpha channel from it, you're done .. at least as far as defining what's transparent and what isn't.

BTW, I rarely cut a shape out of any "fabric" layer as I'm working. That's what the alpha channel is going to do anyway, so why duplicate effort? Besides, cutting out a shape in the fabric layer just invites the nasty white halo effect.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Jill Ordinary
Registered User
Join date: 21 Sep 2009
Posts: 6
11-28-2009 16:03
i love your simple explanation. back to the drawing board. (photoshop)*
seems like the steps are similar, if not, exactly like creating a shirt, or pants,
but with opaque parts. i will try again. Sometimes im slower than others :(
thank you for your help =)

hopefully i will not be back for additional help on this topic..LOL

happy holidays =)
Merlynn Draken
Registered User
Join date: 14 Nov 2006
Posts: 26
11-29-2009 18:28
Jill -- start with a transparent file. Draw your fur. Save as png. Upload. All you will see is the fur. No alpha necessary as long as your file is transparent.
Peggy Paperdoll
A Brat
Join date: 15 Apr 2006
Posts: 4,383
11-29-2009 19:43
I'm getting confused here.........well, I've been confused since this thread first started. I think when we make a "new alpha channel" we are really making a new layer mask instead? I don't use Photoshop so maybe that's what it's called. In GIMP if you want to place an alpha channel in a layer you can simply add one. If you want to define areas or parts of a layer or image to have transparency (the actual use of the alpha channel) you create a layer mask and the same rules apply as any layer mask........black 100% transparent, white 100% opaque, and anything else varying levels of opaque/transparency. I don't know about PS but in GIMP you must "apply" your mask before any transparency is placed in the layer or image.

Don't know if any of my babbling will help but what I'm getting confused over might be what someone is missing in the process.........."apply' is something I've not heard in any discription of how to achieve the transparency desired.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
11-29-2009 20:18
No. Creating a layer mask is one way to produce an alpha channel, but it's not an alpha channel. It's a mask..... a way of isolating portions of a layer so that you can work on other parts without disturbing them. You can select a mask and save it to produce an alpha channel image, but it's not the channel.

And a channel is not "in" a layer either. A channel is a channel. Think of it as an array of instructions applied to each pixel in an image to define the intensity of whatever property is being expressed. In a 32 bit image, we use four channels: R,G,B, and A. For each pixel in an image, the R channel contains information about the intensity of "red". The same for B and G. The alpha channel (A) carries information about the intensity of opacity (or what SL interprets as opacity). The less opacity (i.e., the darker the alpha channel image is), the more transparent the image will be in SL.

Information stored in each pixel by whatever you do in the various layers in your design contributes to the total intensity expressed in each channel, but it's no more correct to say that a layer is "in" a channel than to say the a channel is "in" a layer.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Peggy Paperdoll
A Brat
Join date: 15 Apr 2006
Posts: 4,383
11-29-2009 20:59
I'm glad you straightened me out on that. Amend my "in" to mean adding an additional 8 bits of data to define one more channel to the existing 24 bits already present to produce a 32 bit texture instead of a 24 bit texture. A round about way to say basically the same thing.........you need 32 bits for transparency or 4 channels. Those channels make the image (or the layers within that image) to produce the final desired image. When I said "apply" your mask I guess that is what PS does when you save the mask to your layer or image. Same thing, different terminology.

However, I still have not read anything about "saving" the mask to produce the transparency desired in the image. You can "save" that layer mask to any one or all of the RBG channels depending on what you are doing. That is my point of confusion. And I merely pointed it out that maybe since I got a little confused maybe the OP did too.

I know how to do what the OP wants to do.......but I can't tell her how in PS. A layer is a layer, a channel is a channel, a mask is a mask, and an image is and image no matter what program you use. Once everything is merged and saved in TGA or PNG it's all one layer with all channels smashed together to produce the final desired product.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
11-29-2009 21:26
Neat, Peggy. We're talking about the same thing now, just in different language. In PS, one easy way to create the alpha channel image is to "save" the selected mask as a new channel. That's the language PS uses. Unfortunately it could lead some people to think that the mask IS the channel, rather than just the tool you use to create it.

I still think Robin Woods' tutorial is the absolute best way to understand how an alpha channel works. I notice, in fact, that she has a new one at http://www.robinwood.com/Catalog/Technical/SL-Tuts/SLTutSet.html that is especially nice.

For those who would rather use PNG, that's fine. I agree with Chosen, however, that it is no more difficult to create transparency with TGA and an alpha channel than with PNG, and it's WAY more versatile. Besides, learning how channels work is hands down the best way to get a good feel for how images are put together. It's nice to have more than one way to do things, but I definitely prefer using TGA and alphas.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Tini Jewell
Registered User
Join date: 19 Feb 2007
Posts: 95
12-05-2009 13:34
Not to distract from the OP, but a question to Rolig:

What makes the TGA with Alpha more "versatile"? I don't understand why a TGA with an Alpha Channel would have more capabilities than a PNG. Is something restricted by using the PNG file?

Any explanation is appreciated. Thanks.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
12-05-2009 18:18
To a degree, it comes down to what we're each most comfortable with, Tini, but there's more than comfortable familiarity involved. I became intrigued with the "white halo" problem that many people have when they create transparency with alpha channels, so I took time to figure out why white halos happen. In the process, I discovered that if you understand how alphas channels work, you never create white halos in the first place and never need to clean them up. I also discovered how easy it is to create a good alpha channel, especially if you are trying for subtly graded translucency, as in a folded lace or a dirty window. I could probably write a long post to answer your question, but Chosen Few has done it so many times and so much better that I'd rather paste a chunk of one of his recent posts instead. He is WAAAAY more competent than I am. This is part of a broader commentary on channels in general, but largely focused on alpha channels.....

From: Chosen Few
I could spend weeks assembling a proper list of uses, and that would still only scratch the surface. I'll try to limit this to a few that are immediately obvious for any texture artist, no particular order:

1. If you want to make a texture that grades evenly from opaque to transparent, you can do so in less than a second, simply by putting a black-white gradient on an alpha channel. To try to do it some other way could take hours, and there would be a huge margin for error.

2. For images with highly variable degrees of transparency, such as stained glass windows, proper alpha channel work flow can save countless hours per image, and is totally non-destructive. People who are new to the concept never believe me at first when I say that, since WYSIWYG seems so much more intuitive in the beginning. But every single person I've ever helped to learn the difference has been absolutely floored at how much time and energy they'd previously been wasting.

3. Channel-masking is an extremely fast and efficient means extracting image elements from backgrounds, especially for elements that have complex edging like human hair, furry animals, foliage, etc. Even the seemingly messiest and most chalenging extractions can be done in mere seconds, if you know your way around the channels palette, and have had some practice with applicable techniques. To attempt such extractions with any and all other methods I'm aware of typically will take considerably longer, and the results won't be nearly as clean. (Note, channel masking is slightly different from straight up layer masking, although they are closely related.)

4. Color balancing and adjustments can be done in seconds, simply by manipulating the levels of the primary color channels. This can be far more precise, and much faster than using tools such as the hue/saturation controls.

5. Alpha channels are the only fully controllable means of adding lighting, bumpiness, and other 3D-esque effects to your imagery.

6. The channel/masking mindset as a workflow is infinitely less destructive than typical WYSIWYG workflow. Changes can be applied, reapplied, undone, redone, etc., forever, without ever having to alter the original imagery.

7. Using channels as launching points for contrast masks can add a depth and dimension to photography that is almost unachievable any other way.

8. The effects of practical photographic darkroom filters can be simulated instantly, simply by controlling which channels do and don't receive the full weight of Photoshop filters and effects.

9. By having the transparency map be a separate element from the color maps, transparency values of one image can be applied to another, instantly. I'm not aware of any other method of doing this in any reasonable amount of time.

10. That same transparency map can be used to map any other effect in any capable 2D or 3D rendering program. So, for example, if you want that stained glass window to be shinier on the more opaque parts than the more transparent parts, or bumbier, or more specular, or more reflective, or whatever, all of that can be applied instantly, simply by assigning the alpha map to control those effects as well as just transparency. This is nearly impossible with WYSIWYG workflow, without an absolute ton of extra work.


That's 10 off the top of my head. As I said, I could go on for weeks listing more.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Merlynn Draken
Registered User
Join date: 14 Nov 2006
Posts: 26
12-08-2009 14:59
From: Tini Jewell
Not to distract from the OP, but a question to Rolig:

What makes the TGA with Alpha more "versatile"? I don't understand why a TGA with an Alpha Channel would have more capabilities than a PNG. Is something restricted by using the PNG file?

Any explanation is appreciated. Thanks.



My question as well, Tini, you beat me to it -- how is a tga with an alpha channel more versatile than a png? Perhaps there are features I am not aware of. I gave up creating tga's with alpha channels many moons ago and have never noticed any difference at all, except png files are much smaller than tgas. I do hear people saying how much better tga files are and it always makes me wonder why.
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
12-08-2009 16:26
See my post, above yours. The topic is similar to the question "Which computer is better -- PC or Apple?" You can find vocal partisans willing to argue either side and often unwilling to listen to the other side. That's unfortunate, because PNG and TGA both have advantages and are perfectly good image formats.

For the reasons enumerated in the quote from Chosen's post and for many others, I am most comfortable with using alpha channels and TGA. I find the workflow to be much simpler. I also find it significantly easier to modify an old design that has a large number of layers, any one of which may have degrees of translucency. I suspect that some people who prefer PNG have given up on learning how to create an alpha channel, and prefer it because it's a WYSIWYG method. There's nothing wrong with that -- WYSIWYG is as good a reason as any for choosing a format -- but it's not me.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Pygora Acronym
User
Join date: 20 Feb 2007
Posts: 222
12-08-2009 22:32
Lack of alpha channel isn't a problem with the actual .png format. That's an issue with how Photoshop implemented support for the format since v5 and a user base that doesn't seem to know, or care, that that's the case. The .png format does support alpha channels. It's Photoshop that does not allow you to save them and forces you to use WYSIWYG and make you look uncool.

If you use the SuperPNG plug in then you can save alpha channels in PS, just like like a certain free image editor that doesn't GIMP .pngs *and* have a format that supports greater bit depth per channel and much better compression compared to .tga, along with other features.

Here is a link to image file format features for .png and .tga. http://www.aivosto.com/vbtips/imageformats.html

This isn't comparing PC to Mac at all. It's going out and looking at a the technical specifications of a format finalized in 1989 and one from 2003.