[1/5] WineD3D: Get some vertex pipeline infrastructure in place

Stefan Dösinger stefan at codeweavers.com
Mon Nov 17 08:28:37 CST 2008

> 2008/11/17 Stefan Dösinger <stefan at codeweavers.com>:
> > -    } else if (fixup ||
> > +    } else if (device->vertex_pipe->can_convert_d3dcolor || fixup ||
> Shouldn't this be redundant if you already handle color conversion in
> IWineD3DVertexBufferImpl_FindDecl()?
Not all vertex data comes from a vertex buffer. 'fixup' is always FALSE for Draw[Indexed]PrimitiveUP and DrawPrimitiveStrided.

> > -    } else {
> > +    } else if(!device->vertex_pipe->can_convert_d3dcolor) {
> I don't think this is how we want to do this. I think it makes more
> sense to ask the pipeline if it can handle a particular type for a
> particular usage. You can handle FLOAT16 support in the same way then.
Good point, although in practise we don't have to be able to handle all types with all usages. On some windows drivers e.g. FLOAT16 colors and fixed function fail, and ati returns an error. I think we can make use of that to keep the code simpler.

> Also note that EXT_vertex_array_bgra adds support for D3DCOLOR, but
> only for diffuse, specular and generic attributes. That should be
> enough for anything we come across, but with a "can_convert_d3dcolor"
> flag like that you can't handle that extension properly.
Hmm, I think I should make this a function instead of a flag to deal with EXT_vertex_array_bgra

So better don't apply this patch for now

More information about the wine-devel mailing list