added Doxygen-based documentation (draft version for now)
This commit is contained in:
parent
3b0243c51d
commit
47c3e79423
@ -663,6 +663,14 @@ endif()
|
|||||||
################## LATEX ##################
|
################## LATEX ##################
|
||||||
set(BUILD_LATEX_DOCS OFF CACHE BOOL "Build LaTeX OpenCV Documentation")
|
set(BUILD_LATEX_DOCS OFF CACHE BOOL "Build LaTeX OpenCV Documentation")
|
||||||
|
|
||||||
|
################### DOXYGEN ###############
|
||||||
|
|
||||||
|
find_package(Doxygen)
|
||||||
|
|
||||||
|
if(DOXYGEN_FOUND)
|
||||||
|
set(BUILD_DOXYGEN_DOCS ON CACHE BOOL "Generate HTML docs using Doxygen")
|
||||||
|
endif()
|
||||||
|
|
||||||
# ----------------------------------------------------------------------------
|
# ----------------------------------------------------------------------------
|
||||||
# UPDATE CONFIG FILES & SCRIPTS:
|
# UPDATE CONFIG FILES & SCRIPTS:
|
||||||
#
|
#
|
||||||
@ -1190,10 +1198,17 @@ message(STATUS " Use TBB: NO")
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(BUILD_LATEX_DOCS AND PDFLATEX_COMPILER)
|
if(BUILD_LATEX_DOCS AND PDFLATEX_COMPILER)
|
||||||
message(STATUS " Build Documentation 1")
|
message(STATUS " Build PDF YES")
|
||||||
else()
|
else()
|
||||||
message(STATUS " Build Documentation 0")
|
message(STATUS " Build PDF NO")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(BUILD_DOXYGEN_DOCS AND DOXYGEN_FOUND)
|
||||||
|
message(STATUS " Doxygen HTMLs YES")
|
||||||
|
else()
|
||||||
|
message(STATUS " Doxygen HTMLs NO")
|
||||||
|
endif()
|
||||||
|
|
||||||
message(STATUS "")
|
message(STATUS "")
|
||||||
message(STATUS " Install path: ${CMAKE_INSTALL_PREFIX}")
|
message(STATUS " Install path: ${CMAKE_INSTALL_PREFIX}")
|
||||||
message(STATUS "")
|
message(STATUS "")
|
||||||
|
@ -126,3 +126,38 @@ endif() # BUILD_LATEX_DOCS AND PDFLATEX_COMPILER
|
|||||||
install(FILES ${FILES_DOC} DESTINATION "${OPENCV_DOC_INSTALL_PATH}" COMPONENT main)
|
install(FILES ${FILES_DOC} DESTINATION "${OPENCV_DOC_INSTALL_PATH}" COMPONENT main)
|
||||||
install(FILES ${FILES_DOC_PAPERS} DESTINATION "${OPENCV_DOC_INSTALL_PATH}/papers" COMPONENT main)
|
install(FILES ${FILES_DOC_PAPERS} DESTINATION "${OPENCV_DOC_INSTALL_PATH}/papers" COMPONENT main)
|
||||||
install(FILES ${FILES_DOC_VS} DESTINATION "${OPENCV_DOC_INSTALL_PATH}/vidsurv" COMPONENT main)
|
install(FILES ${FILES_DOC_VS} DESTINATION "${OPENCV_DOC_INSTALL_PATH}/vidsurv" COMPONENT main)
|
||||||
|
|
||||||
|
########################################### Doxygen Docs #########################################
|
||||||
|
|
||||||
|
if(BUILD_DOXYGEN_DOCS AND DOXYGEN_FOUND)
|
||||||
|
|
||||||
|
set(DOXYGEN_LANGUAGE "English" CACHE STRING "Language used by doxygen")
|
||||||
|
mark_as_advanced(DOXYGEN_LANGUAGE)
|
||||||
|
|
||||||
|
set(CMAKE_DOXYGEN_IMAGE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/pics")
|
||||||
|
|
||||||
|
set(module_names core) # imgproc calib3d features2d objdetect video highgui ml legacy contrib)
|
||||||
|
set(DOXYGEN_SOURCE_DIR)
|
||||||
|
set(doxy_html_dep_list)
|
||||||
|
|
||||||
|
foreach(m ${module_names})
|
||||||
|
set(module_hdr_path "${CMAKE_SOURCE_DIR}/modules/${m}/include/opencv2/${m}")
|
||||||
|
set(DOXYGEN_SOURCE_DIR ${DOXYGEN_SOURCE_DIR} ${module_hdr_path})
|
||||||
|
file(GLOB module_hdrs "${module_hdr_path}/*.h*")
|
||||||
|
set(doxy_html_dep_list ${doxy_html_dep_list} ${module_hdrs})
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
set(DOXYGEN_OUTPUT_DIR html)
|
||||||
|
string(REGEX REPLACE ";" " " CMAKE_DOXYGEN_INPUT_LIST "${DOXYGEN_SOURCE_DIR}")
|
||||||
|
|
||||||
|
configure_file(Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
|
||||||
|
set(HTML_TARGET "DOXY_HTML" )
|
||||||
|
|
||||||
|
add_custom_target(${HTML_TARGET} ALL
|
||||||
|
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
|
||||||
|
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile ${doxy_html_dep_list})
|
||||||
|
|
||||||
|
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html/" DESTINATION "${OPENCV_DOC_INSTALL_PATH}/html/" COMPONENT main)
|
||||||
|
|
||||||
|
endif()
|
||||||
|
|
||||||
|
123
doc/Doxyfile.in
Executable file
123
doc/Doxyfile.in
Executable file
@ -0,0 +1,123 @@
|
|||||||
|
# Doxyfile 1.3.9.1
|
||||||
|
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Project related configuration options
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
PROJECT_NAME = opencv
|
||||||
|
PROJECT_NUMBER = @OPENCV_VERSION@
|
||||||
|
OUTPUT_DIRECTORY = .
|
||||||
|
CREATE_SUBDIRS = NO
|
||||||
|
OUTPUT_LANGUAGE = English
|
||||||
|
BRIEF_MEMBER_DESC = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Build related configuration options
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
EXTRACT_ALL = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to warning and progress messages
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
QUIET = NO
|
||||||
|
WARNINGS = YES
|
||||||
|
WARN_IF_UNDOCUMENTED = YES
|
||||||
|
WARN_IF_DOC_ERROR = YES
|
||||||
|
WARN_FORMAT = "$file:$line: $text"
|
||||||
|
WARN_LOGFILE =
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the input files
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
INPUT = @CMAKE_DOXYGEN_INPUT_LIST@
|
||||||
|
FILE_PATTERNS = *.cpp *.h*
|
||||||
|
RECURSIVE = NO
|
||||||
|
EXCLUDE =
|
||||||
|
EXCLUDE_SYMLINKS = NO
|
||||||
|
EXCLUDE_PATTERNS =
|
||||||
|
EXAMPLE_PATH =
|
||||||
|
EXAMPLE_PATTERNS =
|
||||||
|
EXAMPLE_RECURSIVE = NO
|
||||||
|
IMAGE_PATH = @CMAKE_DOXYGEN_IMAGE_PATH@
|
||||||
|
INPUT_FILTER =
|
||||||
|
FILTER_PATTERNS =
|
||||||
|
FILTER_SOURCE_FILES = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the alphabetical class index
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
ALPHABETICAL_INDEX = YES
|
||||||
|
COLS_IN_ALPHA_INDEX = 5
|
||||||
|
IGNORE_PREFIX =
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the HTML output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_HTML = YES
|
||||||
|
HTML_OUTPUT = html
|
||||||
|
HTML_FILE_EXTENSION = .html
|
||||||
|
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the LaTeX output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_LATEX = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the RTF output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_RTF = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the man page output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_MAN = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the XML output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_XML = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options for the AutoGen Definitions output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_AUTOGEN_DEF = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# configuration options related to the Perl module output
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
GENERATE_PERLMOD = NO
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration options related to the preprocessor
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
ENABLE_PREPROCESSING = YES
|
||||||
|
MACRO_EXPANSION = YES
|
||||||
|
EXPAND_ONLY_PREDEF = YES
|
||||||
|
PREDEFINED = CV_EXPORTS= CVAPI(x)=x __cplusplus=1
|
||||||
|
SEARCH_INCLUDES = NO
|
||||||
|
INCLUDE_PATH =
|
||||||
|
INCLUDE_FILE_PATTERNS =
|
||||||
|
EXPAND_AS_DEFINED =
|
||||||
|
SKIP_FUNCTION_MACROS = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration::additions related to external references
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
TAGFILES =
|
||||||
|
GENERATE_TAGFILE =
|
||||||
|
ALLEXTERNALS = NO
|
||||||
|
EXTERNAL_GROUPS = YES
|
||||||
|
PERL_PATH = /usr/bin/perl
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration options related to the dot tool
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
CLASS_DIAGRAMS = YES
|
||||||
|
HIDE_UNDOC_RELATIONS = YES
|
||||||
|
HAVE_DOT = NO
|
||||||
|
CLASS_GRAPH = YES
|
||||||
|
COLLABORATION_GRAPH = YES
|
||||||
|
UML_LOOK = NO
|
||||||
|
TEMPLATE_RELATIONS = YES
|
||||||
|
INCLUDE_GRAPH = YES
|
||||||
|
INCLUDED_BY_GRAPH = YES
|
||||||
|
CALL_GRAPH = NO
|
||||||
|
GRAPHICAL_HIERARCHY = YES
|
||||||
|
DOT_IMAGE_FORMAT = png
|
||||||
|
DOT_PATH =
|
||||||
|
DOTFILE_DIRS =
|
||||||
|
MAX_DOT_GRAPH_WIDTH = 1024
|
||||||
|
MAX_DOT_GRAPH_HEIGHT = 1024
|
||||||
|
MAX_DOT_GRAPH_DEPTH = 0
|
||||||
|
GENERATE_LEGEND = YES
|
||||||
|
DOT_CLEANUP = YES
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
# Configuration::additions related to the search engine
|
||||||
|
#---------------------------------------------------------------------------
|
||||||
|
SEARCHENGINE = YES
|
@ -730,7 +730,7 @@ Returns the number of ticks per second
|
|||||||
\cvdefCpp{double getTickFrequency();}
|
\cvdefCpp{double getTickFrequency();}
|
||||||
|
|
||||||
The function returns the number of ticks per second.
|
The function returns the number of ticks per second.
|
||||||
That is, the following code computes the executing time in seconds.
|
That is, the following code computes the execution time in seconds.
|
||||||
\begin{lstlisting}
|
\begin{lstlisting}
|
||||||
double t = (double)getTickCount();
|
double t = (double)getTickCount();
|
||||||
// do something ...
|
// do something ...
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user