使用Doxygen:
安裝
from: http://www.stack.nl/~dimitri/doxygen/download.html
If you have GIT installed, you should do the following to get the initial copy of the repository:
git clone https://github.com/doxygen/doxygen.git
cd doxygen
After that you can use
mkdir build
cd build
cmake -G "Unix Makefiles" ..
make
To force a fresh build after an earlier check-out simple remove the build directory and redo the steps above.
After the binaries have been built, you can use
make install
to install them.
使用
1 產生設定檔
doxygen -g ProjectNameConfig
2 修改設定
PROJECT_NAME = OpenCV 2.4.9 # 改成自己要的專案名字 PROJECT_NUMBER = 1.0 # 專案的版本 OUTPUT_DIRECTORY = ../docs/OpenCV2.4.9 # 輸出的位置 INPUT = /usr/local/Cellar/opencv/2.4.9 # 讀取的位置 CREATE_SUBDIRS = YES OUTPUT_LANGUAGE = Chinese-Traditional FULL_PATH_NAMES = NO EXTRACT_STATIC = YES FILE_PATTERNS = *.h *.m *.swift #讀進的副檔名, 不需要逗號 RECURSIVE = YES REFERENCED_BY_RELATION = YES REFERENCES_RELATION = YES INLINE_SOURCE = YES EXTRACT_ALL = YES
3 支援繪圖
安裝GraphViz
brew install graphviz
且設定
HAVE_DOT = YES UML_LOOK = YES
4 產生文件檔案
doxygen ProjectNameConfig
★Doxygen都不支持Swift
參考
https://ike35.wordpress.com/2014/10/08/doxygen-install/
留言
張貼留言