Re: [AD] blending regression

[ Thread Index | Date Index | More Archives ]

Elias Pschernig wrote:

We should still try to hide that from the user I think. Use an
ALLEGRO_COLOR throughout user visible structs, then convert before
passing to DX - it just will make things less confusing. And it should
make no difference performance wise - instead of having the user do the
(seemingly pointless) conversion before passing colors on to Allegro
functions, have them pass on ALLEGRO_COLOR and do the conversion

Well... you change from having to do the conversion once at the vertex array creation time, to having to do conversion every time the vertex array is drawn. Plus theres the issue of where to store the transformed vertices, since they can't be transformed in place, I'd have to make (yet another) buffer to store the transformed vertices in.

I suppose I already do that for indexed primitives and old cards for D3D... but I don't really laud those as great successes on my part: they are unavoidable consequences of D3D being... a suboptimal API to do program in. Now at least for this color business this is avoidable via the ALLEGRO_PRIM_COLOR trick... I don't really think it's that bad, and the reason for its existence can be (and already is, I think) documented.

In principle, I could make the conversion work, but it'll be giving the D3D driver the finger. As much as I don't like it, I don't want to make it too disadvantaged against.

I could bring back the vertex buffer paradigm which would go around this... but nobody wants that :P


Mail converted by MHonArc 2.6.19+