Skip to content

Commit a0942b9

Browse files
authored
Merge pull request #1092 from Idclip/doc_improvements
Doxygen Improvements
2 parents 4bdc995 + 780df64 commit a0942b9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+261
-139
lines changed

CHANGES

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1548,8 +1548,7 @@ Version 3.2.0 - August 10, 2016
15481548
- Fixed isApproxZero() so that it works correctly when tolerance is zero.
15491549
[Reported by Joshua Olson]
15501550
- Fixed bugs in tree::NodeUnion that could cause crashes.
1551-
- Fixed memory leak in
1552-
tools::mesh_to_volume_internal::ExpandNarrowband
1551+
- Fixed memory leak in a tools::meshToVolume sub-tool (expandNarrowband).
15531552
[Reported by Kévin Dietrich]
15541553
- Fixed parameter type inconsistencies in math/Stencils.h and
15551554
tools/RayIntersector.h.

ci/extract_test_examples.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,13 @@ for DOC in "${DOCS[@]}"; do
5252
elif [[ $line == @code* ]]; then
5353
str=""
5454
compile="none"
55-
elif [[ $line == "<!--- V --->@code"* ]]; then
55+
elif [[ $line == "<!-- V -->@code"* ]]; then
5656
str=""
5757
compile="volumes"
58-
elif [[ $line == "<!--- P --->@code"* ]]; then
58+
elif [[ $line == "<!-- P -->@code"* ]]; then
5959
str=""
6060
compile="points"
61-
elif [[ $line == "<!--- A --->@code"* ]]; then
61+
elif [[ $line == "<!-- A -->@code"* ]]; then
6262
str=""
6363
compile=""
6464
elif [[ $line == @endcode ]]; then

doc/CMakeLists.txt

Lines changed: 40 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,11 @@ include(GNUInstallDirs)
1919
# with OPENVDB_BUILD_DOCS=ON and either OPENVDB_BUILD_HOUDINI_PLUGIN=ON or
2020
# USE_HOUDINI=ON will define Houdini_VERSION. If Houdini_VERSION is not set,
2121
# all documentation is included.
22-
option(OPENVDB_DOXYGEN_HOUDINI "Build Houdini documentation" ON)
2322
option(OPENVDB_DOXYGEN_AX "Build AX documentation" ON)
23+
option(OPENVDB_DOXYGEN_HOUDINI "Build Houdini documentation" ON)
24+
option(OPENVDB_DOXYGEN_INTERNAL [=[
25+
Enable documentation of methods and classes which have been explicitly marked as internal
26+
]=] OFF)
2427

2528
find_package(Doxygen REQUIRED doxygen)
2629
if(MINIMUM_DOXYGEN_VERSION)
@@ -59,10 +62,12 @@ set(DOXYGEN_FILE_PATTERNS *.h *h.in) # headers only
5962
set(DOXYGEN_EXTENSION_MAPPING .in=C) # parse CMake config headers as C
6063
set(DOXYGEN_IMAGE_PATH "doc/img")
6164
set(DOXYGEN_RECURSIVE NO)
65+
set(DOXYGEN_QUIET YES)
6266

6367
set(DOXYGEN_GENERATE_HTML YES)
6468
set(DOXYGEN_GENERATE_MAN NO)
6569
set(DOXYGEN_GENERATE_LATEX NO)
70+
set(DOXYGEN_GENERATE_TODOLIST NO)
6671

6772
set(DOXYGEN_HTML_COLORSTYLE_HUE 4)
6873
set(DOXYGEN_HTML_COLORSTYLE_SAT 222)
@@ -72,18 +77,36 @@ set(DOXYGEN_EXTRACT_ALL YES)
7277
set(DOXYGEN_EXTRACT_STATIC YES)
7378
set(DOXYGEN_EXTRACT_LOCAL_CLASSES NO)
7479

80+
# Allow for root directory paths to be listed (e.g. openvdb/io/File.h)
81+
# Rather than just the file names (e.g. File.h). This makes it far
82+
# easier to navigate the docs
83+
set(DOXYGEN_FULL_PATH_NAMES YES)
84+
set(DOXYGEN_STRIP_FROM_PATH
85+
"${CMAKE_SOURCE_DIR}/openvdb"
86+
"${CMAKE_SOURCE_DIR}/openvdb_ax"
87+
"${CMAKE_SOURCE_DIR}/openvdb_houdini"
88+
"${CMAKE_SOURCE_DIR}")
89+
set(DOXYGEN_STRIP_FROM_INC_PATH
90+
"${CMAKE_SOURCE_DIR}/openvdb"
91+
"${CMAKE_SOURCE_DIR}/openvdb_ax"
92+
"${CMAKE_SOURCE_DIR}/openvdb_houdini")
93+
94+
# Shows which source files generated the respected doxygen docs
95+
# at the bottom of each html page. Don't bother listing these.
96+
set(DOXYGEN_SHOW_USED_FILES NO)
97+
# When doxygen adds the source code for each header (see VERBATIM_HEADERS)
98+
# don't remove the actual doxygen comments
99+
set(DOXYGEN_STRIP_CODE_COMMENTS NO)
100+
# Don't add an alpha index of all classes (it's not particularly useful)
75101
set(DOXYGEN_ALPHABETICAL_INDEX NO)
76102
set(DOXYGEN_DISTRIBUTE_GROUP_DOC YES)
77-
set(DOXYGEN_FULL_PATH_NAMES NO)
78-
set(DOXYGEN_GENERATE_TODOLIST NO)
79103
set(DOXYGEN_HIDE_IN_BODY_DOCS YES)
80104
set(DOXYGEN_HIDE_SCOPE_NAMES YES)
81105
set(DOXYGEN_INLINE_INHERITED_MEMB YES)
82106
set(DOXYGEN_MACRO_EXPANSION YES)
83-
set(DOXYGEN_CLASS_DIAGRAMS NO) # @todo use dot with class diagrams for relevant classes
84-
set(DOXYGEN_ENABLED_SECTIONS "")
107+
# @todo use dot with class diagrams for relevant classes
108+
set(DOXYGEN_CLASS_DIAGRAMS NO)
85109

86-
set(DOXYGEN_QUIET YES)
87110

88111
set(DOXYGEN_ALIASES
89112
[[ijk="(<i>i</i>,&nbsp;<i>j</i>,&nbsp;<i>k</i>)"]]
@@ -115,8 +138,19 @@ set(DOXYGEN_PREDEFINED
115138
"OPENVDB_VERSION_NAME=v${OpenVDB_MAJOR_VERSION}_${OpenVDB_MINOR_VERSION}"
116139
"OPENVDB_ABI_VERSION_NUMBER=${OpenVDB_MAJOR_VERSION}"
117140
[[__declspec(x):= __attribute__(x):=]]
141+
# Replace the deprecated macros with doxygen deprecated comments. This ensures
142+
# that every bit of deprecated C++ is listed in the doxygen deprecated list,
143+
# even if it was not properly tagged
144+
[["OPENVDB_DEPRECATED=/** \deprecated */"]]
145+
[["OPENVDB_DEPRECATED_MESSAGE(x)=/** \deprecated x */"]]
118146
"OPENVDB_USE_LOG4CPLUS=")
119147

148+
set(DOXYGEN_ENABLED_SECTIONS "")
149+
150+
if(OPENVDB_DOXYGEN_INTERNAL)
151+
list(APPEND DOXYGEN_ENABLED_SECTIONS "OPENVDB_DOCS_INTERNAL")
152+
endif()
153+
120154
if(OPENVDB_DOXYGEN_HOUDINI)
121155
# Append Houdini-specific settings to the Doxygen config file.
122156
if(Houdini_VERSION)

0 commit comments

Comments
 (0)