Re: GLX in bad state
"R." <[email protected]>
| Newsgroups | gmane.comp.emulators.winex.devel |
|---|---|
| Message-ID | <[email protected]> |
Isn't running this with 'winex --debugmsg -all c4demo.exe -- /bench' going to be very slow? I remember when testing some dinput changes I was making that running with -all slows everything down due to the excessive output. Could that be part of the horrible fps you are receiving? What are the results without the debugmsg option on the benchmark? -Ryan aka p0z3r -----Original Message----- From: Nadav Frum <[email protected]> Sent: Mar 31, 2004 6:51 AM To: [email protected] Subject: Re: [Winex-devel] GLX in bad state On Wed, 11 Feb 2004, I started the above thread. My objective was to highlight the shortcomings of the current GLX implementation in comparison to WGL (the Windows implementation). I cited ARB_render_texture as one GLX extension which is urgently needed. I gave a brief explanation as to how this extension may be used to render shadows and reflections. This was a technical and dry explanation. Because this is an important topic I decided it was time for a demonstration. I urge everybody who is able to assist to do so by posting their own results. Below is a patch which will allow Transgamers to run the Comanche 4 Demo benchmark. It adds a stub to a function that is not yet implemented. The C4 benchmark makes lots of use of shadows and reflections. The demo is also freely available for download and includes the benchmark. I believe that the bad performance I am experiencing with this benchmark is due to the absence of ARB_render_texture. The results I get by running the benchmark are as follows: Comanche 4 Benchmark Results for 800x600x32 FSAA=0 VSync=OFF DXTC=ENABLED AUDIO=OFF SHADERS=DISABLED Frames per second: 2.18 avg Tris per second: 431,485 avg My system specs are as follows: CPU: Intel Celeron 1.7 GHz System Memory: 384 MB GPU: GForce4 64 MB 440MX AGP x8 To run the benchmark enter the game's directory and type: winex --debugmsg -all c4demo.exe -- /bench The results will be appended to the 'c4bench.txt' file in the game's directory. If you have access to a Windows machine then the results there will also be valuable. Remember to disable hardware shaders in the pop-up menu because pixel shaders are not yet available in WineX. By disabling sound you will further refine the comparison. This is the patch: --- winex-20031120.new/dlls/d3d8/d3d8_main.c.ofp 2003-11-18 01:10:35.000000000 +0200 +++ winex-20031120.new/dlls/d3d8/d3d8_main.c 2003-12-01 08:53:17.000000000 +0200 @@ -1020,7 +1020,7 @@ Direct3DDevice8_SetPixelShader, Direct3DDevice8_GetPixelShader, (void*)0xdead1061, /* DeletePixelShader */ - (void*)0xdead1062, /* SetPixelShaderConstant */ + Direct3DDevice8_SetPixelShaderConstant, (void*)0xdead1063, /* GetPixelShaderConstant */ (void*)0xdead1064, /* GetPixelShaderFunction */ (void*)0xdead1065, /* DrawRectPatch */ --- winex-20031120.new/dlls/d3d8/pshader.c.ofp 2003-07-30 15:34:54.000000000 +0300 +++ winex-20031120.new/dlls/d3d8/pshader.c 2003-12-01 08:53:17.000000000 +0200 @@ -40,3 +40,14 @@ TRACE("(%p)\n", stuff); return TRUE; } + +HRESULT WINAPI Direct3DDevice8_SetPixelShaderConstant(LPDIRECT3DDEVICE8 iface, + DWORD Register, + CONST void* pConstantData, + DWORD ConstantCount) +{ + /* ICOM_THIS(IDirect3DDevice8Impl, iface); */ + FIXME("(%p)->(%d, %p,%d): stub\n", iface, Register, pConstantData, ConstantCount); + return D3D_OK; +} + --- winex-20031120.new/dlls/d3d8/d3d8_private.h.ofp 2003-10-23 20:14:30.000000000 +0200 +++ winex-20031120.new/dlls/d3d8/d3d8_private.h 2003-12-01 08:53:17.000000000 +0200 @@ -383,6 +383,11 @@ DWORD Handle); HRESULT WINAPI Direct3DDevice8_GetPixelShader(LPDIRECT3DDEVICE8 iface, DWORD* pHandle); +HRESULT WINAPI Direct3DDevice8_SetPixelShaderConstant(LPDIRECT3DDEVICE8 iface, + DWORD Register, + CONST void* pConstantData, + DWORD ConstantCount); + /* state.c */ HRESULT WINAPI Direct3DDevice8_SetTransform(LPDIRECT3DDEVICE8 iface, Nadav Frum ---------- P.S. I believe this patch also stops Operation Flashpoint from crashing.