Re: [AD] DRAW_MODE_TRANS in Zbuffered POLYTYPE_FLAT

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


tom st denis wrote:
> It seems that draw_mode_trans only works if I used non POLYTYPE_ZBUF'ed
> polygons.  Wierd.

I guess that's because correctly drawn translucent z-buffered polygons
would require the z-buffer to remember more than one z coordinate for
each pixel, since two pixels may be (partly) visible at the same time:
if polygon p1 is on top of polygon p2 and p1 is translucent, then next
time we draw to the same position we need to compare the z value both
with p1's z value and with p2's z value to see how to blend the pixels.
So it's technically impossible if you only use one z-buffer.

Sven Sandberg



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/