Commit Graph

3 Commits

Author SHA1 Message Date
baldurk 5adce29b44 Add support for documenting bindings API directly in code 2017-04-18 14:57:41 +01:00
baldurk 66353de7fb Add support for SWIG wrapping python callbacks as std::functions 2017-04-18 14:57:41 +01:00
baldurk 940d3662eb Add SWIG file to generate python bindings for internal replay API
* SWIG outputs two files - renderdoc_python.cpp with the main actual
  wrapping code, and renderdoc.py a small module that does some
  bootstrapping on python side.
* We use a custom version of SWIG that generates strong/typed enums in
  python based on enum classes, so in cmake we add this custom swig
  fork as an external project and compile it before generating the
  wrappers. On windows there's a committed version of the SWIG binary
  that gets run directly from the .pro or .vcxproj.
* The renderdoc.py gets embedded as a resource on windows or as a C
  generated unsigned char array via include-bin on other platforms, so
  that we can insert it into the python context without needing it to
  sit around on disk somewhere in sys.path
2017-04-18 14:57:40 +01:00