
A bigger image as jpeg compression makes it hard to see;

Semi transparent edges simply do not meet.
These forums are CLOSED. Please visit the new forums HERE
is this a known bug? |
|
Wanda Rich
Registered User
![]() Join date: 22 Apr 2006
Posts: 320
|
07-02-2006 05:11
Gaps in joins when transparency is used:
![]() A bigger image as jpeg compression makes it hard to see; ![]() Semi transparent edges simply do not meet. |
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
|
07-02-2006 08:59
A result of rendering engine limitations, to a degree.
When texture is used to paint 3d mesh by game client, the colours aren't taken directly from single pixels of texture but rather from small patches (say, 3x3 pixels) and averaged out. Now, this means when the client uses pixels from texture edge, it'll average it with some non-existing pixels from 'beyond the edge' ... typically, it'll fetch values for these extra pixels either from the _opposite_ texture edge, or generate some extras with whatever value and opacity. Meaning if that opposite edge isn't transparent to the same level, it might result in some of different opacity bleeding in (and if engine uses these 'default' pixels instead then there isn't really anything you can do) This is usually handled either by using different settings for render engine (so say, it uses copy of values from relevant texture edge rather than fetch it from opposite end) or by making the UV-map a tiny bit smaller than the image it uses, so there's 1-2 pixels 'safety band' ... but with SL we have no way to control render settings, and the supplied UV maps leave lot to be desired :< |
Chip Midnight
ate my baby!
![]() Join date: 1 May 2003
Posts: 10,231
|
07-02-2006 09:27
That's why the templates are marked with a "bleed area." You want to make sure that your opaque edges extend beyond the actual mesh edge to the edge of the bleed area. That way when the game engine averages the pixels at the edge it isn't averaging in any tranparent pixels. It also helps things look better while they're still rezzing, since the averaged area is bigger during the first stages of progressive texture loading.
If you're using my templates, make sure your opaque areas extend beyond the outside of the edge matching guide (the multicolored lines on the other edges). _____________________
![]() My other hobby: www.live365.com/stations/chip_midnight |
Wanda Rich
Registered User
![]() Join date: 22 Apr 2006
Posts: 320
|
07-02-2006 11:29
That's why the templates are marked with a "bleed area." You want to make sure that your opaque edges extend beyond the actual mesh edge to the edge of the bleed area. That way when the game engine averages the pixels at the edge it isn't averaging in any tranparent pixels. It also helps things look better while they're still rezzing, since the averaged area is bigger during the first stages of progressive texture loading. If you're using my templates, make sure your opaque areas extend beyond the outside of the edge matching guide (the multicolored lines on the other edges). here is a test everyone can do; make a 512x512 texture, fill the alpha with 50% black and the normal layer with black. Now apply that to a shirt and pants. You still get the gaps even though the document is actually filled |
Compulsion Overdrive
lazy ass
Join date: 10 Jul 2005
Posts: 83
|
07-02-2006 17:42
then do the same thing with a jacket and notice it's fine, its poor uv maping, not a rendering limitation.
|
Wanda Rich
Registered User
![]() Join date: 22 Apr 2006
Posts: 320
|
07-02-2006 18:15
then do the same thing with a jacket and notice it's fine, its poor uv maping, not a rendering limitation. oh its my god ![]() just out of curiosity as this is a bit out of my depth - could it be fixed if someone generated new uvmaps from the exisiting models? or doesn't it work that way? |
Robin Sojourner
Registered User
Join date: 16 Sep 2004
Posts: 1,080
|
07-02-2006 18:34
A bit of background about UV Maps.
![]() The Avatar, as you probably know, is built of polygons, which have points on the corners, where they join other polys. The shape you see on the screen is built of a description of where those points are on the X, Y, and Z axes. Those points can also have positions on a 2 dimensional UV Map, where U is the horizontal and V the vertical axis. That's what a UV Map is. It works by coloring each point on the model according to the color of that point on the texture that's being used by the UV Map. Anything that's not directly under a point is extrapolated. Think of it as a very stretchy piece of rubber or spandex, with the texture painted on it, pinned to the model at the points. When it's doing the extrapolation, it looks in both directions; that's why you need a bleed area. If there is transparency too close to the bleed, that gets averaged into the extrapolation. All UV Maps work this way; not just the ones in SL. It's the nature of the beast. If the model was remapped, there would still need to be a bleed area, and every single piece of clothing, skin, and tattoo in SL would "break," since the textures wouldn't fit the new UV Maps. So, although I'm sure the Lindens will upgrade the model sooner or later, it's going to be fairly traumatic when they do. On the other hand, it's very easy to extend the textures out into the bleed area, and all 3D texture artists everywhere have to do it. ![]() If you want more about exactly how to do that, let us know. Hope this explains things. _____________________
Robin (Sojourner) Wood
www.robinwood.com "Second Life ... is an Internet-based virtual world ... and a libertarian anarchy..." Wikipedia |
Wanda Rich
Registered User
![]() Join date: 22 Apr 2006
Posts: 320
|
07-02-2006 18:41
On the other hand, it's very easy to extend the textures out into the bleed area, and all 3D texture artists everywhere have to do it. ![]() If you want more about exactly how to do that, let us know. Hope this explains things. thanks for the info robin. but... As i pointed out earlier you get this gap even with a 512 texture that is filled from edge to edge. I see the gap between shirt and pants when using textures like this. Earlier today i also cut an alpha that was loacated just above the knee, this was applied to pants, i then inverted the alpha and applied this to socks - the alpha is cut exactly but there is still a gap. This is seen in the first pic at the top of the page. In fact nudging it one pixel vertical produces a black line where they overlap. |
Robin Sojourner
Registered User
Join date: 16 Sep 2004
Posts: 1,080
|
07-02-2006 19:38
Oh, that. Sorry, I misread the question.
Yeah, that happens. You might try feathering the edge of the alpha. I haven't experimented to see if that works, but it might. That happens because of the way the different layers go together on the AV. As far as I can tell, you have your choice of a slight gap, or a slight overlap, if you're using semi-transparency. But, as I said, I haven't tried feathering the edge. It's possible, if you hit it exactly right, that you'll wind up with just enough extrapolation from both sides to fill that gap without overlapping. (Remember, the Alpha is just part of the texture and is also extrapolated, as described in my last post.) You might also try to draw the alpha (which, for some reason, people seem to refer to "cutting," although that's very confusing from my POV) exactly on the vertices. Once again, I have no idea if that would work, but if you feel like experimenting, you might want to try it. _____________________
Robin (Sojourner) Wood
www.robinwood.com "Second Life ... is an Internet-based virtual world ... and a libertarian anarchy..." Wikipedia |