summaryrefslogtreecommitdiff
path: root/d3d9.py
diff options
context:
space:
mode:
authorJosé Fonseca <jose.r.fonseca@gmail.com>2011-04-28 08:48:20 +0100
committerJosé Fonseca <jose.r.fonseca@gmail.com>2011-04-28 08:48:20 +0100
commit46a2db052b7bd310c27b63f72ac6c617457e2f49 (patch)
tree5dcc989b8dc6beda16fa35fb9ed569af441e72cb /d3d9.py
parenta948d39118c504b6c7f2cdd93a2ddfceb6549518 (diff)
Dump D3D9 shaders as text, as done previously.
Diffstat (limited to 'd3d9.py')
-rw-r--r--d3d9.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/d3d9.py b/d3d9.py
index 81d310aa..6db95361 100644
--- a/d3d9.py
+++ b/d3d9.py
@@ -406,12 +406,18 @@ d3d9.add_functions([
class D3D9Tracer(DllTracer):
- pass
+ 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)
+ return
+ DllTracer.dump_arg_instance(self, function, arg)
if __name__ == '__main__':
print '#include "d3d9imports.hpp"'
+ print '#include "d3d9shader.hpp"'
print
print '#include "trace_write.hpp"'
print '#include "os.hpp"'