3 registered members (NewbieZorro, TipmyPip, 1 invisible),
19,045
guests, and 8
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Z-Order problems
#75331
05/24/06 17:59
05/24/06 17:59
|
Joined: Apr 2006
Posts: 14
Sidarta
OP
Newbie
|
OP
Newbie
Joined: Apr 2006
Posts: 14
|
I'm making a racing game and I'm having problems with Z-Order. The track is formed by four models: one, the track itself; two, the high-speed turns; three and four, the guardrails. Their Z-Orders are for some reason wrong, so things are rendered in front or behind of them despite their spatial distribution. Here are some examples: Please, somebody help me!!
|
|
|
Re: Z-Order problems
[Re: jcl]
#75334
05/25/06 09:58
05/25/06 09:58
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
Also, avoid textures with alpha channel or transparency as this often causes Z-sorting problems. However, with a simple material, this part can be worked around.
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
Re: Z-Order problems
[Re: ulillillia]
#75335
06/14/06 15:12
06/14/06 15:12
|
Joined: Nov 2003
Posts: 1,659 San Francisco
JetpackMonkey
Serious User
|
Serious User
Joined: Nov 2003
Posts: 1,659
San Francisco
|
Is this the same problem? I'm using A6.40.5 Extra. I've got these treetops which are box-shaped MDL's, with a TGA skin of leaves. I also tried it with alpha-channeled DDS (dxt3 and 5) and the same thing happens. The leaves are somehow being cut out, wherever the silhouette of the objects inthe background are. They do not intersect, and the background geometry is actually pretty far away. These aren't sprites, they're models with alpha channels. Here you can see what the treetop cube should look like (the problem isn't too visible here): Now here you can see the same treetop cube with the problem significantly more visible. You can also see how the leaves are visible directly in front of the tree (it looks like they are painted on the tree), but obscured by the far-away MDL terrain geometry behind it. This has me stumped (hah little tree joke there). Does anyone know how I could remedy this? I hope there's a way, because the "avoid textures with alpha channel" solution is a non-solution. I'm using 6.40.5 Extra. yours,
|
|
|
Re: Z-Order problems
[Re: JetpackMonkey]
#75336
06/14/06 15:26
06/14/06 15:26
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
Your screenshots aren't showing for some reason (it could be my somewhat unstable internet connection).
Edit: never mind - I had to view the page sounce and click the "retry" button about 5 times just to view the screenshots saying it couldn't find the server....
Just wondering, have you tried making a wall as a model and putting a transparent object behind the wall to see if it renders? This is the simplest of test levels one could make....
Last edited by ulillillia; 06/14/06 15:28.
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
Re: Z-Order problems
[Re: jcl]
#75340
06/14/06 20:01
06/14/06 20:01
|
Joined: Nov 2003
Posts: 1,659 San Francisco
JetpackMonkey
Serious User
|
Serious User
Joined: Nov 2003
Posts: 1,659
San Francisco
|
Hi guys thanks for all your suggestions. Let's see, here's the assessment: 1. The background object is not transparent-- it's a very large piece of MDL geometry. It's a 24 bit dds texture. I tried switching it to bmp but it didn't change this. 3. There aren't any other transparent objects behind this 'treetop' cube on which the texture is. All the other geometry has transparent = 0 and alpha = 100, and 24 bit textures only. 4. I tried changing the d3d_entsort to all three possible settings. It didn't change anything. This was per the manual's entity:transparent section. It mentions the same problem you describe re: intersecting transparent polygons, but in this case there is only this one polygon. But otherwise I didn't see any other solutions mentioned. 5. I tried using 32 bit DDS, and then 32 bit TGA on the 'treetop cube' to see if this would change things. No difference. 6. I tried adding a block skycube to see if that would help, but no difference.  Each image is of the same stuff, only from different angles. Here the order is from closest to furthest away: treetop, grassy hill thing, purple cube. The purple cube is quite far away. I appreciate your insight on this!
|
|
|
|