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
cd1b324e
Commit
cd1b324e
authored
Nov 07, 2016
by
Vitaly Tuzov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for OpenVX based implementation of wrapAffine HAL API
parent
ca1ce5fa
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
10 deletions
+12
-10
openvx_hal.hpp
3rdparty/openvx/include/openvx_hal.hpp
+12
-10
No files found.
3rdparty/openvx/include/openvx_hal.hpp
View file @
cd1b324e
...
@@ -517,8 +517,7 @@ inline int ovx_hal_warpAffine(int atype, const uchar *a, size_t astep, int aw, i
...
@@ -517,8 +517,7 @@ inline int ovx_hal_warpAffine(int atype, const uchar *a, size_t astep, int aw, i
setConstantBorder
(
border
,
(
vx_uint8
)
borderValue
[
0
]);
setConstantBorder
(
border
,
(
vx_uint8
)
borderValue
[
0
]);
break
;
break
;
case
CV_HAL_BORDER_REPLICATE
:
case
CV_HAL_BORDER_REPLICATE
:
border
.
mode
=
VX_BORDER_REPLICATE
;
// Neither 1.0 nor 1.1 OpenVX support BORDER_REPLICATE for warpings
break
;
default
:
default
:
return
CV_HAL_ERROR_NOT_IMPLEMENTED
;
return
CV_HAL_ERROR_NOT_IMPLEMENTED
;
}
}
...
@@ -526,8 +525,9 @@ inline int ovx_hal_warpAffine(int atype, const uchar *a, size_t astep, int aw, i
...
@@ -526,8 +525,9 @@ inline int ovx_hal_warpAffine(int atype, const uchar *a, size_t astep, int aw, i
int
mode
;
int
mode
;
if
(
interpolation
==
CV_HAL_INTER_LINEAR
)
if
(
interpolation
==
CV_HAL_INTER_LINEAR
)
mode
=
VX_INTERPOLATION_BILINEAR
;
mode
=
VX_INTERPOLATION_BILINEAR
;
else
if
(
interpolation
==
CV_HAL_INTER_AREA
)
//AREA interpolation is unsupported
mode
=
VX_INTERPOLATION_AREA
;
//else if (interpolation == CV_HAL_INTER_AREA)
// mode = VX_INTERPOLATION_AREA;
else
if
(
interpolation
==
CV_HAL_INTER_NEAREST
)
else
if
(
interpolation
==
CV_HAL_INTER_NEAREST
)
mode
=
VX_INTERPOLATION_NEAREST_NEIGHBOR
;
mode
=
VX_INTERPOLATION_NEAREST_NEIGHBOR
;
else
else
...
@@ -576,8 +576,7 @@ inline int ovx_hal_warpPerspectve(int atype, const uchar *a, size_t astep, int a
...
@@ -576,8 +576,7 @@ inline int ovx_hal_warpPerspectve(int atype, const uchar *a, size_t astep, int a
setConstantBorder
(
border
,
(
vx_uint8
)
borderValue
[
0
]);
setConstantBorder
(
border
,
(
vx_uint8
)
borderValue
[
0
]);
break
;
break
;
case
CV_HAL_BORDER_REPLICATE
:
case
CV_HAL_BORDER_REPLICATE
:
border
.
mode
=
VX_BORDER_REPLICATE
;
// Neither 1.0 nor 1.1 OpenVX support BORDER_REPLICATE for warpings
break
;
default
:
default
:
return
CV_HAL_ERROR_NOT_IMPLEMENTED
;
return
CV_HAL_ERROR_NOT_IMPLEMENTED
;
}
}
...
@@ -585,8 +584,9 @@ inline int ovx_hal_warpPerspectve(int atype, const uchar *a, size_t astep, int a
...
@@ -585,8 +584,9 @@ inline int ovx_hal_warpPerspectve(int atype, const uchar *a, size_t astep, int a
int
mode
;
int
mode
;
if
(
interpolation
==
CV_HAL_INTER_LINEAR
)
if
(
interpolation
==
CV_HAL_INTER_LINEAR
)
mode
=
VX_INTERPOLATION_BILINEAR
;
mode
=
VX_INTERPOLATION_BILINEAR
;
else
if
(
interpolation
==
CV_HAL_INTER_AREA
)
//AREA interpolation is unsupported
mode
=
VX_INTERPOLATION_AREA
;
//else if (interpolation == CV_HAL_INTER_AREA)
// mode = VX_INTERPOLATION_AREA;
else
if
(
interpolation
==
CV_HAL_INTER_NEAREST
)
else
if
(
interpolation
==
CV_HAL_INTER_NEAREST
)
mode
=
VX_INTERPOLATION_NEAREST_NEIGHBOR
;
mode
=
VX_INTERPOLATION_NEAREST_NEIGHBOR
;
else
else
...
@@ -1132,8 +1132,10 @@ inline int ovx_hal_cvtOnePlaneYUVtoBGR(const uchar * a, size_t astep, uchar * b,
...
@@ -1132,8 +1132,10 @@ inline int ovx_hal_cvtOnePlaneYUVtoBGR(const uchar * a, size_t astep, uchar * b,
#undef cv_hal_warpAffine
#undef cv_hal_warpAffine
#define cv_hal_warpAffine ovx_hal_warpAffine
#define cv_hal_warpAffine ovx_hal_warpAffine
#undef cv_hal_warpPerspective
//OpenVX perspective warp use round to zero policy at least in sample implementation
#define cv_hal_warpPerspective ovx_hal_warpPerspectve
//while OpenCV require round to nearest
//#undef cv_hal_warpPerspective
//#define cv_hal_warpPerspective ovx_hal_warpPerspectve
#undef cv_hal_filterInit
#undef cv_hal_filterInit
#define cv_hal_filterInit ovx_hal_filterInit
#define cv_hal_filterInit ovx_hal_filterInit
...
...
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