----Message d'origine---- >Date: Wed, 14 Jun 2006 22:03:58 -0600 >De: Vitaliy Margolen >A: Raphael >Copie à: wine-devel@winehq.org >Sujet: Re: [WineD3D] fix bug 4872 > >Wednesday, June 14, 2006, 6:51:21 PM, Raphael wrote: >> On Thursday 15 June 2006 02:34, Raphael wrote: >>> Hi, >>> >>> first patch since a long time :) >>> >>> Changelog: >>> - rename WineD3D_(Create|Release)FakeGLContext to WineD3D_(Create| >>> Release)FakeGLContextOnNeed >>> - and if a GL context is already active (and was not a fake context) >>> returns simili fake context with current GL context infos >>> - cleanup not more needed checks >>> >>> fix #4872: make IWineD3DImpl_CheckDeviceType working if a GL context is >>> already active >>> >>> Regards, >>> Raphael > >> Use this patch instead, i let some stupid (and buggy) debug code > >> Regards, >> Raphael > >I think I counted at least 5 indentation stiles in your patch. I understand >staying consistent with the code's style and using your own stile. But 5?! No i only see two problems, and made by use of xemacs (as i have broken my kate install). Anyway i plan to cleanup code in file in a next patch See http://marc.theaimsgroup.com/?l=wine-patches&m=115033272215006&w=2 >> } >You forgot LEAVE_GL(); NO, LEAVE_GL() is done on ReleaseFakeGLContextOnNeed. to permit between two calls to can make X/GLX calls safely >> + case WINED3DFMT_A4R4G4B4: >> + if (4 == rb && 4 == gb && 4 == bb && 4 == ab) return TRUE; >> + break; >Has nothing to do with context. ?? >> + case WINED3DFMT_A8: >> + if (8 == ab) return TRUE; >> + break; >Same here ?? >> if (Adapter >= IWineD3D_GetAdapterCount(iface)) { >> - TRACE("(%p) Failed: Atapter (%u) higher than supported adapters (%u) returning WINED3DERR_INVALIDCALL\n", This, Adapter, IWineD3D_GetAdapterCount(iface)); >> + TRACE_(d3d_caps)("[FAILED: Atapter (%u) higher than supported adapters (%u)]\n", Adapter, IWineD3D_GetAdapterCount(iface)); >> return WINED3DERR_INVALIDCALL; >> } >This one as well. And I haven't seen any traces so far that used square >brackets. Now we will! Have you ever seen D3D traces ? I only made same as IWineD3DImpl_CheckDeviceFormat (for coherency) see http://source.winehq.org/source/dlls/wined3d/directx.c#L1425 Anyway displaying [OK] or [FAILED] for checks results seems a good idea (and easy to find in logs) > >Vitaliy Margolen Regards, Raphael PS: before many complains, my ISP webmail is buggy, sorry :)