Re: [1/3] WineD3D: Use C bitfields to compact the ffp description (try 2)
Stefan Dösinger <stefan(a)codeweavers.com> writes:
@@ -1785,16 +1785,17 @@ void gen_ffp_op(IWineD3DStateBlockImpl *stateblock, struct ffp_settings *setting }; unsigned int i; DWORD ttff; + DWORD cop, aop, carg0, carg1, carg2, aarg0, aarg1, aarg2;
for(i = 0; i < GL_LIMITS(texture_stages); i++) { IWineD3DBaseTextureImpl *texture; if(stateblock->textureState[i][WINED3DTSS_COLOROP] == WINED3DTOP_DISABLE) { settings->op[i].cop = WINED3DTOP_DISABLE; settings->op[i].aop = WINED3DTOP_DISABLE; - settings->op[i].carg0 = settings->op[i].carg1 = settings->op[i].carg2 = 0xffffffff; - settings->op[i].aarg0 = settings->op[i].aarg1 = settings->op[i].aarg2 = 0xffffffff; + settings->op[i].carg0 = settings->op[i].carg1 = settings->op[i].carg2 = -1; + settings->op[i].aarg0 = settings->op[i].aarg1 = settings->op[i].aarg2 = -1;
It's not very clean to store -1 into unsigned variables, the previous code was better IMO. -- Alexandre Julliard julliard(a)winehq.org
On Wed, Jul 30, 2008 at 08:01:55AM -0500, Stefan D?singer wrote:
It's not very clean to store -1 into unsigned variables, the previous code was better IMO. ok, I'll resend
You probably need to specify ~0u otherwise the constant might be deemed to have the wrong type. David -- David Laight: david(a)l8s.co.uk
You probably need to specify ~0u otherwise the constant might be deemed to have the wrong type. This results in a warning again:
../../../dlls/wined3d/utils.c:1796: warning: large integer implicitly truncated to unsigned type
participants (3)
-
Alexandre Julliard -
David Laight -
Stefan Dösinger