How to use doxygen to generate caller and inheritance diagram.

Since I’m a newbie programmer and code in our team is really complicated, I always found myself lost somewhere in the code sea. Luckily our code is doxygenized long times ago, so  I want to try out some cool features of doxygen. The most important feature to me is inheritance diagram and the usage relations between classes. (something like class A has a member of class B) So here is how to do it:

  1. Install graphviz which has a tool called dot that doxygen use to draw those diagrams:

    $ sudo apt-get install graphviz

  3. Set DOT_GRAPH_MAX_NODES and MAX_DOT_GRAPH_DEPTH to some big number.

  4. Generate doxygen files.

  5. Done. Then you will see diagrams as this.
    Here we assume your files are already doxygenized. If you don’t know what doxygen is or how to use doxygen, you may refer to the reference link to find out.

Doxygen Doxygen manual