Skip to content
This repository has been archived by the owner on Jul 7, 2022. It is now read-only.

jtomori/houdini_additional_python_docs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Houdini additional Python documentation

Additional documentation of Houdini Python modules

Info

Generated documentation can be found here

If you did some scripting in Houdini, then chances are that you have found toolutils module quite handy. But searching in Houdini online help is not very helpful, you will not find much information about it. Maybe some useful code snippets, but not its documentation.

As it turns out there are some handy modules coming with Houdini, but they can be a bit hidden to many users. So I decided to do a small project and auto-generate documentation from docstrings from those modules. I used Sphinx for this.

Current documentation was generated from Houdini 16.5.496

Update

My initial approach involved using hython as interpreter for sphinx-build and I was deleting modules which would not import.

It is not needed anymore since I found out autodoc_mock_imports option which you can find in conf.py. This means that listed modules will not be documented, but all modules that depend on them will be documented fine (they will be importable by Sphinx). This allowed me to generate documentation for much more modules. It is still not perfect, but if you have any suggestions, then you are most welcome to let me know :).

Guide (linux)

  • Install Sphinx (e.g. using pip)

    $ pip install sphinx
    
  • Clone this repo and enter it

    $ git clone https://github.com/jtomori/houdini_additional_python_docs.git
    $ cd houdini_additional_python_docs
    
  • Copy Python files from Houdini: $HH/python2.7libs

    $ cp -r $HH/python2.7libs .
    

    $HH will be present after sourcing Houdini environment, if you are outside of Houdini environment, then replace $HH with your Houdini installation directory, e.g.:

    $ cp -r /opt/hfsXX.X.XXX/houdini/python2.7libs .
    

    Some of the modules do not need to be documented, so delete them

    $ rm -r python2.7libs/whoosh python2.7libs/hou.py
    

    Those two modules are already documented

  • Generate rst files from modules

    $ sphinx-apidoc -o source python2.7libs
    
  • Build html documentation

    $ make html
    
  • Now you have nice online documentation of Houdini Python modules, you will find it in build/html directory. You can push it to gh-pages branch.