Related to skinning (problem) -1 reply

Please wait...

Makrin

Dude, fireflies!

50 XP

25th March 2008

0 Uploads

1,257 Posts

0 Threads

#1 10 years ago

Okay. I'm trying to make a skin using GIMP. This is really related to GIMP, but there's something I can't seem to find. How do you make a certain texture/pattern invisible? Like faded, so you can't see it? I'm modefying some arm textures, but I can't find this one thing. If anyone knows GIMP, could they tell me where this feature is please? Thanks!




Guest

I didn't make it!

0 XP

 
#2 10 years ago

You'll have to make an alpha channel. Here's a pretty thorough explanation Manganiac wrote in another thread:

Spoiler: Show
on TGAs, similar to the way you deal with layers there's an "channel" option/window (wich's usually on a tab right next to layers, or you can go window>channels), by default there are 4 starting ones: RGB, Red, Gree and Blue. They're base stuff, hit the button (at the bottom of channels window) "creat new channel", and there it is, your alpha1 channel (dont bother with its name, its allways "alpha1"). Alpha channels are like gray scale layers set in this special "channel", their rgb values are understood as "transparency" on grafics (the image has no transparency, it's the alpha channel that is read for that purpose). There's no rule to what edge of the alpha channel's rgb will be full transparency (black or white), that's generaly defined on the application you'll need it to (tho by default, it's usually, white = opac, black = transparency), on the engine, you define that on "blendfunc" in your shader on PNGs the diference is that you don't use a channel to define transparency, you do it on the base layer of your image (on photoshop if you haven't saved/defined your image as png yet, the base layer will be locked (has a tinny lock), double-click the base layer, and without changing anything just hit "ok", that'll unlock it and u'll be able to erase on it (before doing so, whenever you erase, you would simply paint it your secondary color (basically by default photoshop demands a non transparent background 4 whatever image you're working with)) it's easier to deal with TGAs, simply because you have control of rgb and transparency as separate features, on pngs, they're both on the same layer, so you don't have much freedom as for editing your transparency whenever you want (personaly I work pngs as if they were TGAs (with an alpha channel and no transparency), just that before the end (saving it as png), I use the alpha channel as a selection filter to delete pixels on my base layer (wich results in desired transparency)). (to do this, just hold ctrl and left-click you alpha channel's icon, change to your base layer, hit delete) important shortcuts for dealing with alpha channels: ctrl+a (select all) ctrl+d (deselect all) ctrl+i (invert colors) ctrl+left click layer icon = selects pixels based on transparency ctrl+left click alpha1 channel icon = selects pixels based on rgb values ctrl+shift+i (invert selection), (if you somehow picked white pixels on alpha, do this, and it'll invert the selection and pick the black values) also, at any momment you can copy a image from layer and paste on channels, or virse-versa... eh... the hard part of it, is picking the right shader, as you already noticed, the "blendfunc or alphafunc" lines are the ones that tell transparency and opacity, but it's just a mess to play with, (I never can NEVER remember wich GL_DST_WHATEVER GL_DST_MINUS_WHATEVER sequence gives me desired effect) allways hunt one within the game * some only work dark values (so the texture darkens whatever is behind it, desregards transparency/alpha), since they're writen for images without transparency, they're for jpgs, they're usually found on shaders for dust/black smoke/dark wall marks not sure but it should be: blendfunc GL_ZERO GL_ZERO * some only work light values (only brightens what's behind it also, images without transparency neither alpha/channels), they're usually found on shaders for explosions/flare effects I know this: blendFunc GL_ONE GL_ONE * then there are the shaders who use the alpha channels to define transparency, gotta watch that some define white as transparency, some as black, also, some will give you a solid opc/transparency diferency, and some will use degradation. I know these: alphaFunc GE192 , will give you solid transparency, meaning: will dig holes without degradation, in other words, your pixels, will be either 100% transparent, or 100% opac (on TGAs, black will be transparency, on PNGs, it'll be the transparency itself) and: blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA (big uh?) will give you transparency with degradation (works better on a shader with a base texture behind it) on a final note... pngs shouldn't have pixels with 100% transparency (it's an odd error that happens when the pixel lacks rgb values, in other words, a pixel that's red with 0% transparency, will remain as is, 50%, all the way to ~97% looks as supposed, but above that the pixel goes full white without transparency (not sure why 97%, may be just normalization, as in every 3% transparenacy for the engine looks the same,)) only happens on pngs, not TGAs (in other words a alpha channel can have 100% black pixels (in other words 100% transparency))



Makrin

Dude, fireflies!

50 XP

25th March 2008

0 Uploads

1,257 Posts

0 Threads

#3 10 years ago

Thanks Rapp! That should make my skin much better. Thank you Manganiac also! EDIT: There's nothing in there about JPEGs, which is what i'm using. I'll assume the same method applies? Also, I just looked and I didn't see Alpha layer. I'll check again....




Guest

I didn't make it!

0 XP

 
#4 10 years ago

No problem! The JPEG filetype doesn't support alpha channels, so you'll either have to use png or tga.




Makrin

Dude, fireflies!

50 XP

25th March 2008

0 Uploads

1,257 Posts

0 Threads

#5 10 years ago

Would it work to rename the extension .jpg to .png, then back to jpg when I'd done what I wanted?




Guest

I didn't make it!

0 XP

 
#6 10 years ago

Nah, you'd have to open the image in Gimp and then save it as a .png, and you'd also have to keep it in that filetype to keep the alpha channel.




Makrin

Dude, fireflies!

50 XP

25th March 2008

0 Uploads

1,257 Posts

0 Threads

#7 10 years ago

Okay, thanks!