Hi Kassen,

On Thu, 2010-07-22 at 14:28 +0200, Kassen wrote:

> I think I talked about this before, but now I understand more of it
> and have a clear example;

It's due to the origin of the ribbon primitive being behind the screen,
in fact in the middle of the moving bar. If you change line to:

(define line
    (with-primitive (build-ribbon 2)
        (translate (vector 0 0 3))
        (hint-wire)
        (line-width 3)
        (hint-anti-alias)
        (pdata-set! "p" 0 (vector 0  2 0))
        (pdata-set! "p" 1 (vector 0 -2 0)))) 

Then it works as advertised. Primitives are sorted by comparing the
positions of their origins (which is faster and more controllable than
averaging the vert positions) - you can use (hint-origin) to help see
what's going on.

Transparency should always be considered broken with hardware 3D, so
there are always some trade offs involved.

cheers,

dave

Reply via email to