X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=d3d9.py;h=640d218dc7a8c2b4726d142cd268e6ec92e128ca;hb=35c2793ac758997a0a1c2e558d384ab94754987d;hp=81401627c43385031aad6b3735f07bf7e77f7e48;hpb=9ed672278e79600c4c7ad34a715ecfc4beda9255;p=apitrace diff --git a/d3d9.py b/d3d9.py index 8140162..640d218 100644 --- a/d3d9.py +++ b/d3d9.py @@ -442,10 +442,10 @@ d3d9.add_functions([ StdFunction(HRESULT, "Direct3DCreate9Ex", [(UINT, "SDKVersion"), Out(Pointer(PDIRECT3D9EX), "ppD3D")], fail='D3DERR_NOTAVAILABLE'), StdFunction(Int, "D3DPERF_BeginEvent", [(D3DCOLOR, "col"), (LPCWSTR, "wszName")], fail='-1'), StdFunction(Int, "D3DPERF_EndEvent", [], fail='-1'), - StdFunction(Void, "D3DPERF_SetMarker", [(D3DCOLOR, "col"), (LPCWSTR, "wszName")], fail=''), - StdFunction(Void, "D3DPERF_SetRegion", [(D3DCOLOR, "col"), (LPCWSTR, "wszName")], fail=''), + StdFunction(Void, "D3DPERF_SetMarker", [(D3DCOLOR, "col"), (LPCWSTR, "wszName")]), + StdFunction(Void, "D3DPERF_SetRegion", [(D3DCOLOR, "col"), (LPCWSTR, "wszName")]), StdFunction(BOOL, "D3DPERF_QueryRepeatFrame", [], fail='FALSE'), - StdFunction(Void, "D3DPERF_SetOptions", [(DWORD, "dwOptions")], fail=''), + StdFunction(Void, "D3DPERF_SetOptions", [(DWORD, "dwOptions")]), StdFunction(DWORD, "D3DPERF_GetStatus", [], fail='0'), ]) @@ -455,19 +455,19 @@ class D3D9Tracer(DllTracer): def dump_arg_instance(self, function, arg): # Dump shaders as strings if function.name in ('CreateVertexShader', 'CreatePixelShader') and arg.name == 'pFunction': - print ' DumpShader(%s);' % (arg.name) + print ' DumpShader(Trace::localWriter, %s);' % (arg.name) return DllTracer.dump_arg_instance(self, function, arg) if __name__ == '__main__': - print '#include "d3d9imports.hpp"' - print '#include "d3dshader.hpp"' - print print '#include "trace_writer.hpp"' print '#include "os.hpp"' print + print '#include "d3d9imports.hpp"' + print '#include "d3dshader.hpp"' + print tracer = D3D9Tracer('d3d9.dll') tracer.trace_api(d3d9)