Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
5f8715c8
Commit
5f8715c8
authored
Jul 05, 2012
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed file globbing in documentation parsers
parent
acf356b0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
6 deletions
+13
-6
check_docs2.py
doc/check_docs2.py
+6
-4
rst_parser.py
modules/java/generator/rst_parser.py
+7
-2
No files found.
doc/check_docs2.py
View file @
5f8715c8
import
os
,
sys
,
glob
,
re
import
os
,
sys
,
fnmatch
,
re
sys
.
path
.
append
(
"../modules/python/src2/"
)
sys
.
path
.
append
(
"../modules/java/"
)
sys
.
path
.
append
(
"../modules/java/
generator
"
)
import
hdr_parser
as
hp
import
rst_parser
as
rp
...
...
@@ -185,8 +185,10 @@ def process_module(module, path):
rstparser
.
parse
(
module
,
path
)
rst
=
rstparser
.
definitions
hdrlist
=
glob
.
glob
(
os
.
path
.
join
(
path
,
"include"
,
"opencv2"
,
module
,
"*.h*"
))
hdrlist
.
extend
(
glob
.
glob
(
os
.
path
.
join
(
path
,
"include"
,
"opencv2"
,
module
,
"detail"
,
"*.h*"
)))
hdrlist
=
[]
for
root
,
dirs
,
files
in
os
.
walk
(
os
.
path
.
join
(
path
,
"include"
)):
for
filename
in
fnmatch
.
filter
(
files
,
"*.h*"
):
hdrlist
.
append
(
os
.
path
.
join
(
root
,
filename
))
if
module
==
"gpu"
:
hdrlist
.
append
(
os
.
path
.
join
(
path
,
".."
,
"core"
,
"include"
,
"opencv2"
,
"core"
,
"devmem2d.hpp"
))
...
...
modules/java/generator/rst_parser.py
View file @
5f8715c8
import
os
,
sys
,
re
,
string
,
glob
import
os
,
sys
,
re
,
string
,
fnmatch
allmodules
=
[
"core"
,
"flann"
,
"imgproc"
,
"ml"
,
"highgui"
,
"video"
,
"features2d"
,
"calib3d"
,
"objdetect"
,
"legacy"
,
"contrib"
,
"gpu"
,
"androidcamera"
,
"java"
,
"python"
,
"stitching"
,
"ts"
,
"photo"
,
"nonfree"
,
"videostab"
]
verbose
=
False
show_warnings
=
True
...
...
@@ -125,7 +125,12 @@ class RstParser(object):
def
parse
(
self
,
module_name
,
module_path
=
None
):
if
module_path
is
None
:
module_path
=
"../"
+
module_name
doclist
=
glob
.
glob
(
os
.
path
.
join
(
module_path
,
"doc/*.rst"
))
doclist
=
[]
for
root
,
dirs
,
files
in
os
.
walk
(
os
.
path
.
join
(
module_path
,
"doc"
)):
for
filename
in
fnmatch
.
filter
(
files
,
"*.rst"
):
doclist
.
append
(
os
.
path
.
join
(
root
,
filename
))
for
doc
in
doclist
:
self
.
parse_rst_file
(
module_name
,
doc
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment