On Tue, Mar 05, 2002 at 07:06:22PM -0500, Leif Delgass wrote: > On Tue, 5 Mar 2002, José Fonseca wrote: > > > BTW, I've isolated the problem with the texture locking, it only > happens > when the code between if(mmesa->multitex) { .. } in the _tris > is run. > Don't know why. I've been trying to premult the texture > coordinates, > either within a new _vbtmp template or in the _tris.c > file itself, but I'm > must be doing something wrong because the results > are different and none > is what is should be. > > > My machine locked hard when running multiarb, but there was no > message on > the sys log. > > I think it may have to do with the way the coords are accessed in the > union. With the old code, I had added the w coordinate for the second > texture unit. The Mesa template doesn't support that unless you use ptex
The w coord should be the same for both texture units unless you use the ptex format (which includes an homogeneous texture coordinate). > verticies, so I changed the code to reuse the w coord from the primary > texture. The u1 and v1 coords are accessed now as ui[8] and ui[9] (the > ui[] array is used so we get the hardware floating point format), but I'm The hardware floating point format is the same as the native CPU. As I see it, ui[] is just a convenience to avoid complicated casts. One can always do: *((unsigned int *) (&pv->u0)) to get the float into integers. ui[..] is just sintatic sugar for the compiler. > not sure if this works now that the union has changed to include > different vertex formats. > > -- Leif Delgass http://www.retinalburn.net The ptex must be accounted, both on _tris and on the template since it affects the premultiplication, but e.g., the texobj sample doesn't generate this format and results aren't all correct. In this sample, as well as the tunnel, some trinagles texture prefectly, and others don't. I suspect either because they're in the end of a vertex buffer (and have some special treatment), or because the homogeneous coordinates are being tampered somehow. José Fonseca _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel