another proxy d3d9.dll question (changes dx9.0 vs. dx9.0b/9.0c)

Started by
1 comment, last by himself 16 years, 8 months ago
Hi, I am working on small proxy dll of d3d9.dll and use basic code from www.mikoweb.eu as a basis. The new dll is supposed to grab screenshots every 40 frames. DirectX 9.0 example works fine with 9.0a applications however 9.0b and 9.0c games dont. For example Halo Combat Evolved pops error window with error message: Sorry you need to have Directx 9.0b installed to run this game. Without my proxy dll it works fine. Farcry also capitulates. I think that d3d9.dll architechture changed since the author wrote the examples and this is why it doesnt work - however i dont know what to start with. I checked IDirect3d9 and IDirect3dDevice9 classes but they did not change. I have read also found this information: " The d3d9.dll supplied with WinXP SP2 (version 5.3.2600.2180) has an extra export called "CheckFullscreen" which gets called after "Direct3DCreate9" by some other DirectX code. The proxy d3d9.dll, doesn't have this export and thus, it claims that DirectX 9.0 is not installed. " but i dont know how to repair the code.
Advertisement
Run the real d3d9.dll through depends.exe. That'll tell you what functions it exports, and therefore what functions you need to export from your proxy DLL.

My d3d9.dll exports:
CheckFullscreen
Direct3DShaderValidatorCreate9
PSGPError
PSGPError
D3DPERF_BeginEvent
D3DPERF_EndEvent
D3DPERF_GetStatus
D3DPERF_QueryRepeatFrame
D3DPERF_Setmarker
D3DPERF_SetOptions
D3DPERF_SetRegion
DebugSetLevel
DebugSetMute
Direct3DCreate9

Although I doubt you need to implement all of those. Another thing Halo might do is query the DLL for its version information block. There used to be a sample in the SDK that would check what DX version you have installed (with source code), but I don't know if it still exists, or if it checked the version info block and stuff...
Thank you.
I implemented all of them. Another question is how to set description information of dll file to my project? I tried putting them into .def file, however I got error:
warning LNK4017: DESCRIPTION statement not supported for the target platform; ignored
Do you know how to do it using Microsoft Visual Studio?

This topic is closed to new replies.

Advertisement