diff --git a/docs/README.md b/docs/README.md index 303059dc..6680e8c8 100644 --- a/docs/README.md +++ b/docs/README.md @@ -2,13 +2,19 @@ We use [Sphinx](https://www.sphinx-doc.org) to generate Meshroom's documentation. +## Requirements + To install all the requirements for building the documentation, simply run: ```bash pip install sphinx sphinx-rtd-theme myst-parser ``` +You also need to have [Graphviz](https://graphviz.org/) installed. + > Note: since Sphinx will import the entire `meshroom` package, all requirements for Meshroom must also be installed +## Build + To generate the documentation, go to the `docs` folder and run the Sphinx makefile: ```bash cd meshroom/docs diff --git a/docs/source/_templates/autosummary/class.rst b/docs/source/_templates/autosummary/class.rst index 03dc3878..958658a3 100644 --- a/docs/source/_templates/autosummary/class.rst +++ b/docs/source/_templates/autosummary/class.rst @@ -1,6 +1,9 @@ {{ fullname | escape | underline}} +.. inheritance-diagram:: {{ fullname }} + + .. meshroom_doc:: :module: {{ module }} :class: {{ objname }} diff --git a/docs/source/conf.py b/docs/source/conf.py index 6f58c912..33c201d9 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -26,7 +26,9 @@ extensions = [ 'sphinx.ext.autodoc', 'sphinx.ext.autosummary', 'fetch_md', - 'meshroom_doc' + 'meshroom_doc', + 'sphinx.ext.graphviz', + 'sphinx.ext.inheritance_diagram' ] templates_path = ['_templates']