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
165f2520
Commit
165f2520
authored
Jun 07, 2010
by
Maria Dimashova
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed sift wrapper
parent
61f06d9b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
sift.cpp
modules/features2d/src/sift.cpp
+7
-4
No files found.
modules/features2d/src/sift.cpp
View file @
165f2520
...
...
@@ -2006,13 +2006,16 @@ SIFT::SIFT( const CommonParams& _commParams,
inline
KeyPoint
vlKeypointToOcv
(
const
VL
::
Sift
::
Keypoint
&
vlKeypoint
,
float
angle
)
{
return
KeyPoint
(
vlKeypoint
.
x
,
vlKeypoint
.
y
,
3
*
vlKeypoint
.
sigma
,
angle
,
0
,
vlKeypoint
.
o
,
0
);
return
KeyPoint
(
vlKeypoint
.
x
,
vlKeypoint
.
y
,
SIFT
::
DescriptorParams
::
GET_DEFAULT_MAGNIFICATION
()
*
vlKeypoint
.
sigma
*
5
/* 5==NBP+1 */
,
angle
,
0
,
vlKeypoint
.
o
,
0
);
}
inline
void
ocvKeypointToVl
(
const
KeyPoint
&
ocvKeypoint
,
const
VL
::
Sift
&
vlSift
,
VL
::
Sift
::
Keypoint
&
vlKeypoint
)
VL
::
Sift
::
Keypoint
&
vlKeypoint
,
int
magnification
)
{
vlKeypoint
=
vlSift
.
getKeypoint
(
ocvKeypoint
.
pt
.
x
,
ocvKeypoint
.
pt
.
y
,
ocvKeypoint
.
size
/
3
);
vlKeypoint
=
vlSift
.
getKeypoint
(
ocvKeypoint
.
pt
.
x
,
ocvKeypoint
.
pt
.
y
,
ocvKeypoint
.
size
/
(
magnification
*
5
)
/* 5==NBP+1 */
);
}
float
computeKeypointOrientations
(
VL
::
Sift
&
sift
,
const
VL
::
Sift
::
Keypoint
&
keypoint
,
int
angleMode
)
...
...
@@ -2100,7 +2103,7 @@ void SIFT::operator()(const Mat& img, const Mat& mask,
for
(
int
pi
=
0
;
iter
!=
keypoints
.
end
();
++
iter
,
pi
++
)
{
VL
::
Sift
::
Keypoint
vlkpt
;
ocvKeypointToVl
(
*
iter
,
vlsift
,
vlkpt
);
ocvKeypointToVl
(
*
iter
,
vlsift
,
vlkpt
,
descriptorParams
.
magnification
);
float
angleVal
=
iter
->
angle
*
CV_PI
/
180.0
;
if
(
descriptorParams
.
recalculateAngles
)
{
...
...
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