Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv_contrib
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_contrib
Commits
fd004893
Commit
fd004893
authored
Aug 16, 2019
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'upstream/3.4' into merge-3.4
parents
b56b3739
bb1dee17
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
33 deletions
+33
-33
dictionary.cpp
modules/aruco/src/dictionary.cpp
+30
-30
reg_shift.py
modules/reg/samples/reg_shift.py
+3
-3
No files found.
modules/aruco/src/dictionary.cpp
View file @
fd004893
...
...
@@ -268,37 +268,37 @@ Mat Dictionary::getBitsFromByteList(const Mat &byteList, int markerSize) {
Ptr
<
Dictionary
>
getPredefinedDictionary
(
PREDEFINED_DICTIONARY_NAME
name
)
{
// DictionaryData constructors calls
// moved out of globals so construted on first use, which allows lazy-loading of opencv dll
static
const
Dictionary
DICT_ARUCO_DATA
=
Dictionary
(
Mat
(
1024
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_ARUCO_BYTES
),
5
,
0
);
static
const
Dictionary
DICT_4X4_50_DATA
=
Dictionary
(
Mat
(
50
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
static
const
Dictionary
DICT_4X4_100_DATA
=
Dictionary
(
Mat
(
100
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
static
const
Dictionary
DICT_4X4_250_DATA
=
Dictionary
(
Mat
(
250
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
static
const
Dictionary
DICT_4X4_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
0
);
static
const
Dictionary
DICT_5X5_50_DATA
=
Dictionary
(
Mat
(
50
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
3
);
static
const
Dictionary
DICT_5X5_100_DATA
=
Dictionary
(
Mat
(
100
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
3
);
static
const
Dictionary
DICT_5X5_250_DATA
=
Dictionary
(
Mat
(
250
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
2
);
static
const
Dictionary
DICT_5X5_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
2
);
static
const
Dictionary
DICT_6X6_50_DATA
=
Dictionary
(
Mat
(
50
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
6
);
static
const
Dictionary
DICT_6X6_100_DATA
=
Dictionary
(
Mat
(
100
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
5
);
static
const
Dictionary
DICT_6X6_250_DATA
=
Dictionary
(
Mat
(
250
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
5
);
static
const
Dictionary
DICT_6X6_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
4
);
static
const
Dictionary
DICT_7X7_50_DATA
=
Dictionary
(
Mat
(
50
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
9
);
static
const
Dictionary
DICT_7X7_100_DATA
=
Dictionary
(
Mat
(
100
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
8
);
static
const
Dictionary
DICT_7X7_250_DATA
=
Dictionary
(
Mat
(
250
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
8
);
static
const
Dictionary
DICT_7X7_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
6
);
static
const
Dictionary
DICT_APRILTAG_16h5_DATA
=
Dictionary
(
Mat
(
30
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_16h5_BYTES
),
4
,
0
);
static
const
Dictionary
DICT_APRILTAG_25h9_DATA
=
Dictionary
(
Mat
(
35
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_25h9_BYTES
),
5
,
0
);
static
const
Dictionary
DICT_APRILTAG_36h10_DATA
=
Dictionary
(
Mat
(
2320
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_36h10_BYTES
),
6
,
0
);
static
const
Dictionary
DICT_APRILTAG_36h11_DATA
=
Dictionary
(
Mat
(
587
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_36h11_BYTES
),
6
,
0
);
// DictionaryData constructors calls
const
Dictionary
DICT_ARUCO_DATA
=
Dictionary
(
Mat
(
1024
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_ARUCO_BYTES
),
5
,
0
);
const
Dictionary
DICT_4X4_50_DATA
=
Dictionary
(
Mat
(
50
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
const
Dictionary
DICT_4X4_100_DATA
=
Dictionary
(
Mat
(
100
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
const
Dictionary
DICT_4X4_250_DATA
=
Dictionary
(
Mat
(
250
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
1
);
const
Dictionary
DICT_4X4_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_4X4_1000_BYTES
),
4
,
0
);
const
Dictionary
DICT_5X5_50_DATA
=
Dictionary
(
Mat
(
50
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
3
);
const
Dictionary
DICT_5X5_100_DATA
=
Dictionary
(
Mat
(
100
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
3
);
const
Dictionary
DICT_5X5_250_DATA
=
Dictionary
(
Mat
(
250
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
2
);
const
Dictionary
DICT_5X5_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_5X5_1000_BYTES
),
5
,
2
);
const
Dictionary
DICT_6X6_50_DATA
=
Dictionary
(
Mat
(
50
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
6
);
const
Dictionary
DICT_6X6_100_DATA
=
Dictionary
(
Mat
(
100
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
5
);
const
Dictionary
DICT_6X6_250_DATA
=
Dictionary
(
Mat
(
250
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
5
);
const
Dictionary
DICT_6X6_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_6X6_1000_BYTES
),
6
,
4
);
const
Dictionary
DICT_7X7_50_DATA
=
Dictionary
(
Mat
(
50
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
9
);
const
Dictionary
DICT_7X7_100_DATA
=
Dictionary
(
Mat
(
100
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
8
);
const
Dictionary
DICT_7X7_250_DATA
=
Dictionary
(
Mat
(
250
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
8
);
const
Dictionary
DICT_7X7_1000_DATA
=
Dictionary
(
Mat
(
1000
,
(
7
*
7
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_7X7_1000_BYTES
),
7
,
6
);
const
Dictionary
DICT_APRILTAG_16h5_DATA
=
Dictionary
(
Mat
(
30
,
(
4
*
4
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_16h5_BYTES
),
4
,
0
);
const
Dictionary
DICT_APRILTAG_25h9_DATA
=
Dictionary
(
Mat
(
35
,
(
5
*
5
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_25h9_BYTES
),
5
,
0
);
const
Dictionary
DICT_APRILTAG_36h10_DATA
=
Dictionary
(
Mat
(
2320
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_36h10_BYTES
),
6
,
0
);
const
Dictionary
DICT_APRILTAG_36h11_DATA
=
Dictionary
(
Mat
(
587
,
(
6
*
6
+
7
)
/
8
,
CV_8UC4
,
(
uchar
*
)
DICT_APRILTAG_36h11_BYTES
),
6
,
0
);
Ptr
<
Dictionary
>
getPredefinedDictionary
(
PREDEFINED_DICTIONARY_NAME
name
)
{
switch
(
name
)
{
case
DICT_ARUCO_ORIGINAL
:
...
...
modules/reg/samples/reg_shift.py
View file @
fd004893
...
...
@@ -7,12 +7,12 @@ import sys
img1
=
cv
.
imread
(
sys
.
argv
[
1
])
img1
=
img1
.
astype
(
np
.
float32
)
shift
=
np
.
array
([
5.
,
5.
])
mapTest
=
cv
.
reg
.
MapShift
(
shift
)
mapTest
=
cv
.
reg
_
MapShift
(
shift
)
img2
=
mapTest
.
warp
(
img1
)
mapper
=
cv
.
reg
.
MapperGradShift
()
mappPyr
=
cv
.
reg
.
MapperPyramid
(
mapper
)
mapper
=
cv
.
reg
_
MapperGradShift
()
mappPyr
=
cv
.
reg
_
MapperPyramid
(
mapper
)
resMap
=
mappPyr
.
calculate
(
img1
,
img2
)
mapShift
=
cv
.
reg
.
MapTypeCaster_toShift
(
resMap
)
...
...
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